News for hackers. Stuff that matters.
Re:Reading a Programmer's Guide to Common Lisp by ogogmad on Thursday February 22, 2024 @09:49AM (#39467892)
Why would a variable declaration be executed conditionally, unless you can somehow GOTO past the declaration? CL doesn't let you do that, does it?

> top level lexical scope

What does this mean? Every single other language lets you write:

   var x = y;
Why is Lisp seemingly the only (imperative) language that doesn't?
Re:Reading a Programmer's Guide to Common Lisp by pfdietz on Thursday February 22, 2024 @11:15AM (#39469246)
One reason to not allow this is that it breaks the equivalence that (for example)

   (progn <form>)
is equivalent to

    <form>
Re:Reading a Programmer's Guide to Common Lisp by martinflack on Thursday February 22, 2024 @12:39PM (#39470415)
^ This is huge. A lot of top-level macro usage would be really annoying to implement if wrapping a PROGN around top-level commands neutered their effect.
Re:Reading a Programmer's Guide to Common Lisp by medo-bear on Thursday February 22, 2024 @10:25AM (#39468444)
> Why would a variable declaration be executed conditionally, unless you can somehow GOTO past the declaration? CL doesn't let you do that, does it?

http://clhs.lisp.se/Body/s_tagbod.htm#tagbody

http://clhs.lisp.se/Body/s_go.htm#go