[R6RS] modules

R. Kent Dybvig dyb
Tue Aug 24 11:17:25 EDT 2004


As I think harder about this "require-for-syntax" stuff, I've decided
that I prefer that plain require make the module available both at expand
time and at run time, so we would have something like:

(require M) makes M's bindings available for expand and run time

(require for-run-time M) makes M's bindings available only for run time

(require for-expand-time M) makes M's bindings available only for expand time

This seems more symmetrical, and otherwise, people are going to be
surprised when:

  (module A (f) (define f ---))

  (module B (a)
    (define-syntax a
      (lambda (x)
        (require A)
        (f x))))

doesn't work.  This default would correspond nicely with an implicit
require in the module form that declares the language both for expand-time
and run-time.

Kent


More information about the R6RS mailing list