emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/dash f61769d 256/316: * dash.el (dash--keywords): Prefe


From: ELPA Syncer
Subject: [elpa] externals/dash f61769d 256/316: * dash.el (dash--keywords): Prefer rx.
Date: Mon, 15 Feb 2021 15:58:12 -0500 (EST)

branch: externals/dash
commit f61769dd3a29307017f990fc573431c9abebb0d5
Author: Basil L. Contovounesios <contovob@tcd.ie>
Commit: Basil L. Contovounesios <contovob@tcd.ie>

    * dash.el (dash--keywords): Prefer rx.
---
 dash.el | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/dash.el b/dash.el
index edbb357..66fa4a2 100644
--- a/dash.el
+++ b/dash.el
@@ -2939,15 +2939,16 @@ structure such as plist or alist."
 (defvar dash--keywords
   `(;; TODO: Do not fontify the following automatic variables
     ;; globally; detect and limit to their local anaphoric scope.
-    (,(concat "\\_<" (regexp-opt '("acc" "it" "it-index" "other")) "\\_>")
+    (,(rx symbol-start (| "acc" "it" "it-index" "other") symbol-end)
      0 font-lock-variable-name-face)
     ;; Macros in dev/examples.el.  Based on `lisp-mode-symbol-regexp'.
-    (,(concat "(" (regexp-opt '("defexamples" "def-example-group") t)
-              "\\_>[\t ]+\\(\\(?:\\sw\\|\\s_\\|\\\\.\\)*\\)")
+    (,(rx ?\( (group (| "defexamples" "def-example-group")) symbol-end
+          (+ (in "\t "))
+          (group (* (| (syntax word) (syntax symbol) (: ?\\ nonl)))))
      (1 font-lock-keyword-face)
      (2 font-lock-function-name-face))
     ;; Symbols in dev/examples.el.
-    ,(concat "\\_<" (regexp-opt '("=>" "~>" "!!>")) "\\_>")
+    ,(rx symbol-start (| "=>" "~>" "!!>") symbol-end)
     ;; Elisp macro fontification was static prior to Emacs 25.
     ,@(when (< emacs-major-version 25)
         (let ((macs '("!cdr"



reply via email to

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