Subject: Re: MAP (and variants) vs LOOP - Popular opinion observation?
From: rpw3@rpw3.org (Rob Warnock)
Date: Thu, 03 Aug 2006 23:09:10 -0500
Newsgroups: comp.lang.lisp
Message-ID: <N9CdnZSJ0pv7VU_ZnZ2dnUVZ_v2dnZ2d@speakeasy.net>
Matthew D Swank  <akopa-is-very-much-like-my-mail-address@c.net> wrote:
+---------------
| I really loathed 'do' until I realized it looked like a "'let' in motion".
| Though, it looks so much like functional code, I would sometimes forget
| that each iteration does not generate a fresh set of bindings for the
| loop variables.
+---------------

This is one of the "gotchas" I occasionally bumped into while I was
in the process of moving over from Scheme to CL several years ago.
The Scheme spec requires that each iteration generate a fresh set
of bindings for the variables, while the CLHS requires that the
variables be bound but once and then subsequently assigned-to
["in parallel, as if by PSETQ" for DO, and "sequentially, as if
by SETQ" for DO*].


-Rob

-----
Rob Warnock			<rpw3@rpw3.org>
627 26th Avenue			<URL:http://rpw3.org/>
San Mateo, CA 94403		(650)572-2607