Klaus Schilling <email@example.com> wrote:
| > There's nothing in the CL stantard per se, but the function you
| > describe would, in CL, commonly be done using LOOP to avoid possible
| > stack overflow for *large* values of (- END START):
| would an iteration with "do" or a tail recursive formulation work?
As others have said, tail recursion [or more generally,
tail call optimization] is not required in Common Lisp,
and is not possible in the general case in the presence of
dynamic variable bindings or exception handler bindings.
Thus, lacking "safe-for-space" tail call optimization,
one can run into the stack overflow issue I mentioned.
 Yes, yes, I know there have been some exotic ways
proposed to handle tail call optimization in the
presence of dynamic variable bindings, but I don't
know of any implementation that does so. And even
then exception handler bindings would mess things up.
Rob Warnock <firstname.lastname@example.org>
627 26th Avenue <URL:http://rpw3.org/>
San Mateo, CA 94403 (650)572-2607