On 18 Sep 2009, at 6:36 pm, Brian Harvey wrote: > Okay, I read the links. I stand by my proof by contradiction. > > What these messages point out is that two things are inconsistent: > > 1. Lisp's 50-year-old, wildly-successful, intuitive, powerful, > productive, > easy-to-specify interactive repl; > > 2. PLT's weird, incomprehensible, unprecedented, unproven, bizarre > notion > of what top-level definition should mean. > > Okay, you've convinced me: one of these has to go.
Tsk, tsk, tsk. That sort of argument can be used to slap down any attempt to improve something established. When you try and experiment with new ideas, there are always problems that you find as you work out how best to approach it. The REPL is lovely and useful, yes. And being able to copy and paste the source of a program or library from a file into the REPL, or to save a REPL session and make it the source of a program or library, is desirable. AIUI, it's not hard to make a compiler given a module or program imbue it with the semantics of the REPL, but it's hard to make the REPL imbue code with the semantics available when doing a whole-source analysis of a program or module (eg, allow arbitrary forward references). Meanwhile, syntax-rules macros are sufficiently restricted as to avoid the issue. And R6RS has mandated the latter semantics, which makes conforming REPLs all but impossible. And in practice, many implementations actually implement a somewhat suboptimal state of affairs as things stand, with confusions about the interactions of scopes of macro and value bindings in various contexts that trip users up. Is that a fair summary of the situation, before we get too carried away insulting each other? :-) If so, we have two choices: Limit whole-program constructs (begin, modules, compiled programs) to have the semantics of the REPL; or live with them having broader semantics. Either of them are fine by me... ABS -- Alaric Snell-Pym Work: http://www.snell-systems.co.uk/ Play: http://www.snell-pym.org.uk/alaric/ Blog: http://www.snell-pym.org.uk/archives/author/alaric/ _______________________________________________ r6rs-discuss mailing list [email protected] http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss
