[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
eval-case and toplevel prohibitions
From: |
Andy Wingo |
Subject: |
eval-case and toplevel prohibitions |
Date: |
Mon, 02 Mar 2009 23:51:43 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Hi all,
I've been hacking at the compiler in recent days, separating out
expansion from compilation (currently they are intertwingled, which
produces some bugs), and making GHIL a more simple language, more
amenable to optimization.
I've grown to really like syncase in its psyntax.scm incarnation. (I
have something of a Dybvig adoration complex.) It has in it an eval-when
construct, but eval-when doesn't have separate rules for toplevel and
nontoplevel, just '(eval compile load):
http://www.scheme.com/csug7/system.html#g91 (see the section on eval-when)
So I was thinking: why do we have this fetish for prohibiting certain
forms in a non-toplevel context? I am of a mind to replace eval-case
with eval-when, which is actually more expressive, as it allows us to
discriminate the different phases in non-toplevel contexts as well.
Cheers,
Andy
--
http://wingolog.org/
- eval-case and toplevel prohibitions,
Andy Wingo <=