GNU bug report logs - #12255
24.2; [PATCH] wrong regexp in c-basic-matchers-before

Previous Next

Package: emacs;

Reported by: Leo <sdl.web <at> gmail.com>

Date: Wed, 22 Aug 2012 03:05:02 UTC

Severity: normal

Tags: patch

Found in version 24.2

Done: Leo <sdl.web <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 12255 in the body.
You can then email your comments to 12255 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-cc-mode <at> gnu.org, bug-gnu-emacs <at> gnu.org:
bug#12255; Package emacs. (Wed, 22 Aug 2012 03:05:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Leo <sdl.web <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-cc-mode <at> gnu.org, bug-gnu-emacs <at> gnu.org. (Wed, 22 Aug 2012 03:05:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Leo <sdl.web <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.2; [PATCH] wrong regexp in c-basic-matchers-before
Date: Wed, 22 Aug 2012 11:04:10 +0800
It seems to me this regexp in c-basic-matchers-before would never
succeed unless @ is of word syntax.

(concat "\\<"
        (regexp-opt
         '("@interface" "@implementation" "@protocol")
         t)
        "\\>")

Should this patch be applied?

diff --git a/lisp/progmodes/cc-fonts.el b/lisp/progmodes/cc-fonts.el
index 2d116e1e..f0f40d54 100644
--- a/lisp/progmodes/cc-fonts.el
+++ b/lisp/progmodes/cc-fonts.el
@@ -855,7 +855,7 @@ (c-lang-defconst c-basic-matchers-before
 
 	    ;; The @interface/@implementation/@protocol directives.
 	    ,(c-make-font-lock-search-function
-	      (concat "\\<"
+	      (concat "\\_<"
 		      (regexp-opt
 		       '("@interface" "@implementation" "@protocol")
 		       t)




Reply sent to Leo <sdl.web <at> gmail.com>:
You have taken responsibility. (Wed, 22 Aug 2012 05:56:01 GMT) Full text and rfc822 format available.

Notification sent to Leo <sdl.web <at> gmail.com>:
bug acknowledged by developer. (Wed, 22 Aug 2012 05:56:01 GMT) Full text and rfc822 format available.

Message #10 received at 12255-done <at> debbugs.gnu.org (full text, mbox):

From: Leo <sdl.web <at> gmail.com>
To: 12255-done <at> debbugs.gnu.org
Cc: bug-cc-mode <at> gnu.org
Subject: Re: bug#12255: 24.2; [PATCH] wrong regexp in c-basic-matchers-before
Date: Wed, 22 Aug 2012 13:54:31 +0800
On 2012-08-22 11:04 +0800, Leo wrote:
> It seems to me this regexp in c-basic-matchers-before would never
> succeed unless @ is of word syntax.

Sorry for the noise.

The syntax for @ is word thanks to c-identifier-syntax-modifications.

Leo




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 19 Sep 2012 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 12 years and 273 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.