[cl-typesetting-devel] CLISP support
Klaus Weidner
kw at w-m-p.com
Sun Apr 25 20:05:10 UTC 2004
On Sun, Apr 25, 2004 at 09:39:58PM +0200, Marc Battyani wrote:
> LW returns 0 not 0.0. It's better IMO as number variables are to be
> initialized with 0 (or 0.0 for a float) though we should not rely on it
> based on the standard. Anyway nil is also an arbitrary value so (or
> max-height 0) is not compliant either.
I'll have a shot at rewriting this in a compatible way. The variable
needs to be initialized for all code paths. An easy way would be adding a
simple "maximize 0 into max-height" somewhere, but there should be
something cleaner.
> The major advantage of iterate is that it is AFAIK there is only one version
> and the source is public :)
Good point ;-)
> > I don't agree - the standard specifies sequential *binding* as in DO vs.
> > DO*, but it does not mention anywhere that this has anything to do with
> > the semantics of the end tests.
>
> In 6.1.2.1 Iteration Control:
> "When iteration control clauses are used in a loop, the corresponding
> termination tests in the loop body are evaluated before any other loop body
> code is executed."
> For me "any other" applies to other clauses as well. The reference to do and
> do* is unfortunate because they have only one termination form.
I think that interpretation goes beyond what the standard actually says.
and I would interpret "loop body" to exclude the stepping statements,
My mental picture of LOOP construct is this:
prologue
unless (end tests)
loop body
stepping statements
epilogue
That's basically equivalent to how the reference section in PG's "ANSI
Common Lisp" defines it.
There's no way to deduce from the standard that end tests and stepping
statements are supposed to be intermingled with each other.
> Unfortunally the standard is ambiguous on several points. Some time ago
> there was a problem with CMUCL and parse-integer. Again the standard could
> be interpreted in 2 ways. Finally they decided to go back to the
> interpretation of all the other implementations. Maybe the CLISP developpers
> will agree to do the same. (ie interpret the standard like all the other
> implementations)
Maybe it would be better if you send the note to the CLISP people, since
I'm mostly convinced of their point of view by now (except for on-list).
-Klaus
More information about the cl-typesetting-devel
mailing list