chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-users] hygienic chicken (getting better, but still problems)


From: felix winkelmann
Subject: [Chicken-users] hygienic chicken (getting better, but still problems)
Date: Mon, 9 Jun 2008 11:39:34 +0200

Hi!

I have tried to improve the usability of the module system and exported
macro definitions now fully close over their lexical environment. Now modules
and indirect exports work, but, alas, unfortunately, hygienic macros break now
inside modules, due to some unidentified problem. I'm working on it.
Any help would be appreciated, as it is difficult to isolate small test-cases
that may help to fix the problems (currently I get the errors when using
relatively large modules (the srfi-42 ref. impl. for example), which generates
tons of debug output).

Things to note: "import" forms make exports available for the next toplevel
form (inside or outside a module) and identifiers referenced by exported
macros must be listed as "indirect" exports:

(module foo (f1 (s1 f2))
  (import scheme)
  (define (f1 ...) ...)        ; exported
  (define (f2 ...) ...)        ; not exported, but used by s2
  (define-syntax s1
    (syntax-rules ()
      ((_ ...) ... f2 ...) ) ) )

This is only necessary for bindings defined inside "foo", not imported
ones.


cheers,
felix




reply via email to

[Prev in Thread] Current Thread [Next in Thread]