[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
&WHOLE with other args...
- To: KMP at MIT-MC
- Subject: &WHOLE with other args...
- From: JONL at MIT-MC (Jon L White)
- Date: Mon, 3 Nov 80 11:39:00 GMT
- Cc: (BUG LISP) at MIT-MC
- Original-date: 3 NOV 1980 0639-EST
You may have misinterpreted the semantics of &WHOLE
Date: 3 November 1980 06:01-EST
From: Kent M. Pitman <KMP at MIT-MC>
. . .
I should hope you don't make this work! Asking for it to work is like
(DEFUN FOO (&REST BAR &OPTIONAL BAZ) (LIST BAR BAZ))
(FOO 3 4)
((3 4) 3)
... yuk! You should have to do
(DEFUN FOO (&WHOLE FORM) (LET ((W (CDR FORM))) ...))
in order to win. -kmp
Whereas &optional and &rest (and all the "&requireds") are necessarily
sequentially parsed, &whole is totally independent of all of them.