GNU bug report logs -
#54743
CC Mode 5.35.1 (C/*l); Incorrect fontification of function call as function name
Previous Next
Reported by: Po Lu <luangruo <at> yahoo.com>
Date: Wed, 6 Apr 2022 02:06:02 UTC
Severity: normal
Done: Alan Mackenzie <acm <at> muc.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Hello again, Po.
On Wed, Apr 06, 2022 at 10:05:36 +0800, Po Lu via CC-Mode-help wrote:
> Package: cc-mode
> Open src/haikumenu.c in the Emacs source code, and go to line 352. The
> calls to `process_pending_signals' and `internal_catch_all' are
> fontified as function names, which is wrong.
> Thanks.
> Emacs : GNU Emacs 29.0.50 (build 1, x86_64-unknown-haiku, Haiku R1/beta3, cairo version 1.16.0)
> of 2022-04-06
> Package: CC Mode 5.35.1 (C/*l)
> Buffer Style: GNU
> c-emacs-features: (pps-extended-state col-0-paren posix-char-classes gen-string-delim gen-comment-delim syntax-properties 1-bit)
It looks like the bug was a "simple" mistyping. I think the following
patch, which is literally a 1-bit change, should fix the problem. Would
you please try it out, and confirm to me that it does indeed fix the
problem. Thanks!
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el
index ebc1ef4301..b2fa9e0691 100644
--- a/lisp/progmodes/cc-engine.el
+++ b/lisp/progmodes/cc-engine.el
@@ -6139,7 +6139,7 @@ c-update-brace-stack
(setq s (cons -1 (cdr s))))
((and (equal match ",")
(eq (car s) -1))) ; at "," in "class foo : bar, ..."
- ((member match '(";" "*" "," "("))
+ ((member match '(";" "*" "," ")"))
(when (and s (cdr s) (<= (car s) 0))
(setq s (cdr s))))
((c-keyword-member kwd-sym 'c-flat-decl-block-kwds)
--
Alan Mackenzie (Nuremberg, Germany).
This bug report was last modified 3 years and 40 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.