bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#13819: 24.3.50; keywords args are no more font-locked


From: Thierry Volpiatto
Subject: bug#13819: 24.3.50; keywords args are no more font-locked
Date: Tue, 26 Feb 2013 20:43:37 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Thierry Volpiatto <address@hidden> writes:

> Thierry Volpiatto <address@hidden> writes:
>
>> Thierry Volpiatto <address@hidden> writes:
>>
>>> "Drew Adams" <address@hidden> writes:
>>>
>>>>> >> looks like keywords args are no more font-locked:
>>>>> >> e.g :group, :type, &optional etc...
>>>>> >
>>>>> > See bugs #13767 and #13755.
>>>>> 
>>>>> Thanks Drew, found the last but not #13767.
>>>>
>>>> It is here - see the last part about `&optional'.
>>>> http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13767
>>>
>>> Ok thanks, got it on gmane too.
>>
>> Looks like the problem comes from this commit:
>>
>> ,----
>> | commit 3885cfcaa8293ce29760022faeab6a8213a87827
>> | Author: Stefan Monnier <address@hidden>
>> | Date:   Sun Feb 17 11:58:12 2013 -0500
>> `----
> Modifying these regexps make `&optional', `:sources' etc... font-locked
> again :-):
>
> diff --git a/lisp/font-lock.el b/lisp/font-lock.el
> index e5ce4db..de71cf5 100644
> --- a/lisp/font-lock.el
> +++ b/lisp/font-lock.el
> @@ -2336,9 +2336,9 @@ in which C preprocessor directives are used. e.g. 
> `asm-mode' and
>         ("`\\(\\(?:\\sw\\|\\s_\\)\\(?:\\sw\\|\\s_\\)+\\)'"
>          (1 font-lock-constant-face prepend))
>         ;; Constant values.
> -       ("\\<:\\(?:\\sw\\|\\s_\\)+\\>" 0 font-lock-builtin-face)
> +       (":\\(?:\\sw\\|\\s_\\)+" 0 font-lock-builtin-face)
>         ;; ELisp and CLisp `&' keywords as types.
> -       ("\\<\\&\\(?:\\sw\\|\\s_\\)+\\>" . font-lock-type-face)
> +       ("\\&\\(?:\\sw\\|\\s_\\)+" . font-lock-type-face)
>         ;; ELisp regexp grouping constructs
>         ((lambda (bound)
>            (catch 'found

Even better is this one:

diff --git a/lisp/font-lock.el b/lisp/font-lock.el
index e5ce4db..9436012 100644
--- a/lisp/font-lock.el
+++ b/lisp/font-lock.el
@@ -2336,9 +2336,9 @@ in which C preprocessor directives are used. e.g. 
`asm-mode' and
        ("`\\(\\(?:\\sw\\|\\s_\\)\\(?:\\sw\\|\\s_\\)+\\)'"
         (1 font-lock-constant-face prepend))
        ;; Constant values.
-       ("\\<:\\(?:\\sw\\|\\s_\\)+\\>" 0 font-lock-builtin-face)
+       ("\\_<:\\(?:\\sw\\|\\s_\\)+\\_>" 0 font-lock-builtin-face)
        ;; ELisp and CLisp `&' keywords as types.
-       ("\\<\\&\\(?:\\sw\\|\\s_\\)+\\>" . font-lock-type-face)
+       ("\\_<\\&\\(?:\\sw\\|\\s_\\)+\\_>" . font-lock-type-face)
        ;; ELisp regexp grouping constructs
        ((lambda (bound)
           (catch 'found

-- 
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 






reply via email to

[Prev in Thread] Current Thread [Next in Thread]