[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
multiple-values alternative with better destructuring
- To: john@linus.mitre.org, info-dylan@cambridge.apple.com
- Subject: multiple-values alternative with better destructuring
- From: miller@cs.rochester.edu
- Date: Mon, 4 Jan 93 13:58:35 -0500
- In-reply-to: john@linus.mitre.org's message of Mon, 04 Jan 93 13:37:29 EST <9301041837.AA16809@thelonius.mitre.org>
> Date: Mon, 04 Jan 93 13:37:29 EST
> From: john@linus.mitre.org
> They all do. All CommonLisp forms, and all Dylan forms, return
> multiple values. For most of them, N=1, for some N=0 or N>1.
> John Burger
> john@mitre.org
Unless dpans changed it...
All commonlisp forms do not; prog1 returns 1 value, you have to use
multiple-value-prog1 to get >1 value; prog2 does not, setq,etc. See page
184-187 in cltl/2 - there are several other special cases where multiple
values are NOT preserved.
If dpans did change any of this, I'd be grateful for a reply. All I
found on cursory examination is the prog1/multiple-value-prog1
distinction does still exist, so "all commonlisp forms" clearly do NOT
return multiple values.