diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2021-03-11 21:47:10 -0500 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2021-03-11 21:47:10 -0500 |
commit | 7109307c1a62fb3ab781989d495bacd3c2b15a2e (patch) | |
tree | a3732c4344f33353bdde81d50e5fd9e1f99d6b51 /lisp/emacs-lisp/syntax.el | |
parent | b08b2e03b255c0ad85bd026a8d786b21ee22eee8 (diff) | |
download | emacs-7109307c1a62fb3ab781989d495bacd3c2b15a2e.tar.gz emacs-7109307c1a62fb3ab781989d495bacd3c2b15a2e.tar.bz2 emacs-7109307c1a62fb3ab781989d495bacd3c2b15a2e.zip |
* lisp/emacs-lisp/syntax.el (syntax-propertize-rules): Use `macroexp-let2`
This also silences the recently introduced compilation warning.
Diffstat (limited to 'lisp/emacs-lisp/syntax.el')
-rw-r--r-- | lisp/emacs-lisp/syntax.el | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/lisp/emacs-lisp/syntax.el b/lisp/emacs-lisp/syntax.el index bee2f9639e7..6d5b04b83bb 100644 --- a/lisp/emacs-lisp/syntax.el +++ b/lisp/emacs-lisp/syntax.el @@ -290,12 +290,13 @@ all RULES in total." ',(string-to-syntax (nth 1 action))) ,@(nthcdr 2 action)) `((let ((mb (match-beginning ,gn)) - (me (match-end ,gn)) - (syntax ,(nth 1 action))) - (if syntax - (put-text-property - mb me 'syntax-table syntax)) - ,@(nthcdr 2 action))))) + (me (match-end ,gn))) + ,(macroexp-let2 nil syntax (nth 1 action) + `(progn + (if ,syntax + (put-text-property + mb me 'syntax-table ,syntax)) + ,@(nthcdr 2 action))))))) (t `((let ((mb (match-beginning ,gn)) (me (match-end ,gn)) |