[r6rs-discuss] Why does begin not have a body?

From: Jeff Read <bitwize>
Date: Fri Oct 13 17:19:52 2006

On 10/13/06, Alan Watson <alan_at_alan-watson.org> wrote:
> The behaviour of begin already depend on its context: if it occurs in a
> body, it splices; if it does not, it simply sequences. Why not keep the
> splicing behaviour when it occurs in a body, but have begin introduce a
> new body when it occurs outside of a body?

Its behavior is different, but its scoping rules are the same in
either case. To me this seems cleaner, and makes code easier to read
and comprehend. But I may have simply been soured on Python's
"interesting" scoping rules. :)

--Jeff
Received on Fri Oct 13 2006 - 17:19:46 UTC

This archive was generated by hypermail 2.3.0 : Wed Oct 23 2024 - 09:15:01 UTC