]> git.eshelyaron.com Git - emacs.git/commitdiff
Give ,@ a prefix syntax in elisp-mode
authorLars Ingebrigtsen <larsi@gnus.org>
Tue, 7 Jun 2022 18:28:05 +0000 (20:28 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Tue, 7 Jun 2022 18:28:05 +0000 (20:28 +0200)
* lisp/progmodes/elisp-mode.el (elisp-mode-syntax-propertize):
Give ,@ a prefix syntax so that we can properly identify symbols
that follow it, i.e., ,@foo (bug#44418).

lisp/progmodes/elisp-mode.el

index 77bf3f1ed181cba88aad3886c1481086cc5889b9..210270bc679aca8af392c0df99104392ca6eacae 100644 (file)
@@ -245,6 +245,9 @@ Comments in the form will be lost."
       ;; Empty symbol.
       ("##" (0 (unless (nth 8 (syntax-ppss))
                  (string-to-syntax "_"))))
+      ;; Give ,@ a prefix syntax.
+      (",@" (0 (unless (ppss-comment-or-string-start (syntax-ppss))
+                 (string-to-syntax "'"))))
       ;; Unicode character names.  (The longest name is 88 characters
       ;; long.)
       ("\\?\\\\N{[-A-Za-z0-9 ]\\{,100\\}}"