Signal an error when `setf' gets an odd number of arguments.
* lisp/emacs-lisp/gv.el (setf): Amend.
This commit is contained in:
parent
9f1a5113e1
commit
b6bc4ab20c
1 changed files with 2 additions and 0 deletions
|
@ -260,6 +260,8 @@ The return value is the last VAL in the list.
|
|||
|
||||
\(fn PLACE VAL PLACE VAL ...)"
|
||||
(declare (debug (&rest [gv-place form])))
|
||||
(if (/= (logand (length args) 1) 0)
|
||||
(signal 'wrong-number-of-arguments (list 'setf (length args))))
|
||||
(if (and args (null (cddr args)))
|
||||
(let ((place (pop args))
|
||||
(val (car args)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue