mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-24 06:20:43 -08:00
* lisp/emacs-lisp/backquote.el (backquote-process): Catch uses of , and ,@
with more than one argument. Fixes: debbugs:15538
This commit is contained in:
parent
87c4314d27
commit
f2223371ed
2 changed files with 12 additions and 2 deletions
|
|
@ -153,11 +153,18 @@ LEVEL is only used internally and indicates the nesting level:
|
|||
(list 'quote s))))
|
||||
((eq (car s) backquote-unquote-symbol)
|
||||
(if (<= level 0)
|
||||
(cons 1 (nth 1 s))
|
||||
(if (> (length s) 2)
|
||||
;; We could support it with: (cons 2 `(list . ,(cdr s)))
|
||||
;; But let's not encourage such uses.
|
||||
(error "Multiple args to , are not supported: %S" s)
|
||||
(cons 1 (nth 1 s)))
|
||||
(backquote-delay-process s (1- level))))
|
||||
((eq (car s) backquote-splice-symbol)
|
||||
(if (<= level 0)
|
||||
(cons 2 (nth 1 s))
|
||||
(if (> (length s) 2)
|
||||
;; (cons 2 `(append . ,(cdr s)))
|
||||
(error "Multiple args to ,@ are not supported: %S" s)
|
||||
(cons 2 (nth 1 s)))
|
||||
(backquote-delay-process s (1- level))))
|
||||
((eq (car s) backquote-backquote-symbol)
|
||||
(backquote-delay-process s (1+ level)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue