emacs-diffs
[Top][All Lists]
Advanced

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

emacs-29 909091d757 2/2: ; Minor cleanup for tree-sitter font-lock rules


From: Yuan Fu
Subject: emacs-29 909091d757 2/2: ; Minor cleanup for tree-sitter font-lock rules in js-ts-mode
Date: Wed, 28 Dec 2022 20:35:09 -0500 (EST)

branch: emacs-29
commit 909091d7578b7225601b202fb9257dedae879e9a
Author: Yuan Fu <casouri@gmail.com>
Commit: Yuan Fu <casouri@gmail.com>

    ; Minor cleanup for tree-sitter font-lock rules in js-ts-mode
    
    * lisp/progmodes/js.el (js--treesit-font-lock-settings): Minor cleanup.
---
 lisp/progmodes/js.el | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el
index 211d4d7d80..4dece11d1c 100644
--- a/lisp/progmodes/js.el
+++ b/lisp/progmodes/js.el
@@ -3479,20 +3479,17 @@ This function is intended for use in 
`after-change-functions'."
   (treesit-font-lock-rules
 
    :language 'javascript
-   :override t
    :feature 'comment
-   `((comment) @font-lock-comment-face)
+   '((comment) @font-lock-comment-face)
 
    :language 'javascript
-   :override t
    :feature 'constant
-   `(((identifier) @font-lock-constant-face
+   '(((identifier) @font-lock-constant-face
       (:match "^[A-Z_][A-Z_\\d]*$" @font-lock-constant-face))
 
      [(true) (false) (null)] @font-lock-constant-face)
 
    :language 'javascript
-   :override t
    :feature 'keyword
    `([,@js--treesit-keywords] @font-lock-keyword-face
      [(this) (super)] @font-lock-keyword-face)
@@ -3569,8 +3566,7 @@ This function is intended for use in 
`after-change-functions'."
 
    :language 'javascript
    :feature 'jsx
-   `(
-     (jsx_opening_element
+   '((jsx_opening_element
       [(nested_identifier (identifier)) (identifier)]
       @font-lock-function-name-face)
 
@@ -3588,7 +3584,7 @@ This function is intended for use in 
`after-change-functions'."
 
    :language 'javascript
    :feature 'number
-   `((number) @font-lock-number-face
+   '((number) @font-lock-number-face
      ((identifier) @font-lock-number-face
       (:match "^\\(:?NaN\\|Infinity\\)$" @font-lock-number-face)))
 



reply via email to

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