[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: loop macro



    Date: Wed, 5 Feb 86 10:08 EST
    From: Bernard S. Greenberg <BSG@SCRC-STONY-BROOK.ARPA>

	Date: 04 Feb 86 20:52:41 EST (Tue)
	From: Liz Allen <liz@brillig.umd.edu>

	The mention of connecting words kind of puzzles me (and at the same
	time helps me to understand the Lisp Machine loop macro).  Our for
	macro doesn't seem to need them (though it does use "by" and "until").

    What are "let", "initially", "eachtime", "in", "on", "from", "bind", "being",
    "finally", in your macro, if not connecting words, or am I totally confused?

Indeed.  Furthermore, the basic syntax you gave is too basic for me to
understand the syntax of your proposal, since, for example, you didn't
say what an <iteration-spec> looked like.  Furthermore, what does a
<condition-spec> do; that is, what does "when <form*>" mean?  Does that
means that the first form following the "when" is tested, and the rest
are implicit-progn'ed consequents?  What does "eachtime" mean and how is
it different from "do"?

It would help a lot to see an example, too.  How would you translate
this into your "for" construct?  If you can't deal with "until" clauses
at the end of the loop, say so and move it to the front and translate
that instead.  Thanks.

(loop for a from start to end by 5
      for b in list
      do (do-something a b)
      until (null b))