emacs-diffs
[Top][All Lists]
Advanced

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

emacs-29 8f53fa10d94 7/7: Fontify "this" as a keyword in c++-ts-mode (bu


From: Yuan Fu
Subject: emacs-29 8f53fa10d94 7/7: Fontify "this" as a keyword in c++-ts-mode (bug#59924)
Date: Fri, 9 Dec 2022 19:46:45 -0500 (EST)

branch: emacs-29
commit 8f53fa10d9453f36aa601e5943cb903adeacc7fe
Author: Brian Leung <leungbk@posteo.net>
Commit: Yuan Fu <casouri@gmail.com>

    Fontify "this" as a keyword in c++-ts-mode (bug#59924)
    
    * lisp/progmodes/c-ts-mode.el (c-ts-mode--font-lock-settings):
    Following c++-mode, fontify as a keyword instead of a constant.
---
 lisp/progmodes/c-ts-mode.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el
index 7b41718a745..824325d83e0 100644
--- a/lisp/progmodes/c-ts-mode.el
+++ b/lisp/progmodes/c-ts-mode.el
@@ -234,14 +234,14 @@ MODE is either `c' or `cpp'."
      (false) @font-lock-constant-face
      (null) @font-lock-constant-face
      ,@(when (eq mode 'cpp)
-         '((this) @font-lock-constant-face
-           (nullptr) @font-lock-constant-face)))
+         '((nullptr) @font-lock-constant-face)))
 
    :language mode
    :feature 'keyword
    `([,@(c-ts-mode--keywords mode)] @font-lock-keyword-face
      ,@(when (eq mode 'cpp)
-         '((auto) @font-lock-keyword-face)))
+         '((auto) @font-lock-keyword-face
+           (this) @font-lock-keyword-face)))
 
    :language mode
    :feature 'operator



reply via email to

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