On Thu, Apr 27, 2017 at 12:55:12PM -0400, John Cowan wrote:
> On Thu, Apr 27, 2017 at 12:14 PM, Peter Bex <pe...@more-magic.net> wrote:
> > Now, the spec disallows this (I think..),
> 
> Yes, it does:  begin-with-defines is allowed only at top level.  It should
> be replaced by (let () (define ...) . body) instead.  In Algol or C terms,
> begin is a compound statement, let is a block.

True, but "it is an error" to put definitions inside a begin
that's not at toplevel, so we're free to do whatever we want.

Allowing definitions inside begin is quite a useful extension of
the standard, especially when it comes to macros that introduce
multiple definitions; otherwise, those macros could only be used
at toplevel.

Cheers,
Peter

Attachment: signature.asc
Description: Digital signature

_______________________________________________
Chicken-hackers mailing list
Chicken-hackers@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-hackers

Reply via email to