emacs-diffs
[Top][All Lists]
Advanced

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

master bf026b8e556: Tighten regexp for rust-ts-mode keyword workaround


From: Yuan Fu
Subject: master bf026b8e556: Tighten regexp for rust-ts-mode keyword workaround
Date: Thu, 2 May 2024 00:51:12 -0400 (EDT)

branch: master
commit bf026b8e55626b35144f93056744f3fd50bc126b
Author: Yuan Fu <casouri@gmail.com>
Commit: Yuan Fu <casouri@gmail.com>

    Tighten regexp for rust-ts-mode keyword workaround
    
    * lisp/progmodes/rust-ts-mode.el (rust-ts-mode--font-lock-settings):
    Add bos and eos.
---
 lisp/progmodes/rust-ts-mode.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/progmodes/rust-ts-mode.el b/lisp/progmodes/rust-ts-mode.el
index 7bc05898d15..baf0e1ec013 100644
--- a/lisp/progmodes/rust-ts-mode.el
+++ b/lisp/progmodes/rust-ts-mode.el
@@ -217,7 +217,7 @@ to be checked as its standard input."
      ;; If these keyword are in a macro body, they're marked as
      ;; identifiers.
      ((identifier) @font-lock-keyword-face
-      (:match ,(rx (or "else" "in" "move")) @font-lock-keyword-face)))
+      (:match ,(rx bos (or "else" "in" "move") eos) @font-lock-keyword-face)))
 
    :language 'rust
    :feature 'number



reply via email to

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