On Tue, 2009-09-15 at 19:56 -0400, Aaron W. Hsu wrote:
> On Mon, 14 Sep 2009 20:45:50 -0400, Brian Harvey <[email protected]>
> wrote:
> > I don't care about R6RS programs, but loaded files should work as if
> > typed at the REPL.
> Why? And the fact that you don't care about R6RS programs may indicate a
> potentially detrimental bias some of the Scheme community.
His bias is no more potentially detrimental than yours. Can both of you
please accept that others' needs and required modes of use are unlike
your own and stop bickering?
In this case there's a good semantics that achieves what you both want
anyway. LOAD isn't a library-level or module-level primitive anyway.
It has almost[1] the same requirements as "#include" in C, as a
form that requests that the contents of a(nother) file be inserted
at the call site in the current scope. Let it be evaluated just as
it would be if the file were text at the call site in the current
scope.
Bear
[1]almost: it doesn't have quite the same semantics as #include,
because LOAD forms have to start and end in the same scope and
lexical context, and that context has to be a context where the
LOAD form can be evaluated. Therefore LOAD doesn't really make
sense with files containing, eg, the middle of a string or
symbol, nor with unbalanced forms that have more open-parens
than close-parens or vice versa, nor with files containing
unbalanced string quotes.
_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss