Abdulaziz Ghuloum scripsit: > I think one-pass gives you an approximation of let*-scoping > semantics while two-pass gives you recursive bindings. For > example, the following expression > > (let-syntax ((f (syntax-rules () ((_) 1)))) > (let () > (define (g) (f)) > (define (f) 2) > (g))) > > evaluates to 1 in one-pass since at the time (f) is expanded, > only the outer f is known. In two-pass, it evaluates to 2 > since (f) is expanded after the shadowing definition of f is > found.
On my system, at least, Bigloo returns 1; PLT, Gauche, Chicken, scsh, Kawa, SISC, and Petite Chez all return 2; and Gambit and Guile return syntax errors. None of these systems, AFAIK, are two-pass in the sense of R6RS. -- We do, doodley do, doodley do, doodley do, John Cowan <[email protected]> What we must, muddily must, muddily must, muddily must; Muddily do, muddily do, muddily do, muddily do, http://www.ccil.org/~cowan Until we bust, bodily bust, bodily bust, bodily bust. --Bokonon _______________________________________________ r6rs-discuss mailing list [email protected] http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss
