Subject: Re: Implementation of control structures
From: (Rob Warnock)
Date: Tue, 04 Apr 2006 22:55:21 -0500
Newsgroups: comp.lang.lisp
Message-ID: <>
Eli Gottlieb  <> wrote:
| Block and return-from actually work now, and as soon as I find out where 
| an environment is being released I'll be using them to make continuations.
| The tough part is going to be tagbody/go.

Indeed. I would have started there first, actually, since once
you have the full generality[1] of TAGBODY/GO working you can
easily implement BLOCK and RETURN-FROM in terms of TAGBODY/GO:

Besides, you need TAGBODY working to implement DO, DOTIMES,
DOLIST, DO-{,ALL-,EXPERNAL-}SYMBOLS and others which have
"implicit tagbodies" in their bodies.


[1] Specifically, the ability to GO from within a nested LAMBDA:

      > (tagbody
	  (mapc (lambda (x)
		  (print x)
		  (when (eql x 13)
		    (go bye-bye)))
		'(3 5 6 13 1 2 7 8))


Rob Warnock			<>
627 26th Avenue			<URL:>
San Mateo, CA 94403		(650)572-2607