> The output of the do macro (all macros) gets re-expanded until it's fully in core form.
Ok, this is not the the case it seems, as letrec is passed to eval-core, and hence wont be expanded further by the expander.
Example: (do ((x 0 (+ x 1))) ((> x 10)) (display 12))
What is passed to eval-core: (letrec ((g$loop$226 (case-lambda ((g$x$228) (if (> g$x$228 '10) (if '#f '#f (void)) (begin (display '12) (g$loop$226 (+ g$x$228 '1)))))))) (g$loop$226 '0))
Now eval-core will use the implementation based letrec, and not the one from psyntax.
> The output of the do macro (all macros) gets re-expanded until it's fully in core form.
Ok, this is not the the case it seems, as letrec is passed to eval-core, and hence wont be expanded further by the expander.
Example:
(do ((x 0 (+ x 1)))
((> x 10))
(display 12))
What is passed to eval-core:
(case- lambda
( (g$x$228)
(begin (display '12) (g$loop$226 (+ g$x$228 '1))))))))
(letrec ((g$loop$226
(if (> g$x$228 '10)
(if '#f '#f (void))
(g$loop$226 '0))
Now eval-core will use the implementation based letrec, and not the one from psyntax.