[plt-scheme] macro in modules
At Tue, 25 Jul 2006 10:37:40 +0200 (CEST), Ivanyi Peter wrote:
> When I execute the module and require it then I get:
>
> (begin (define (a w) (let* ((q nil) (e nil)) (+ w 1))) 'a)
>
> which is correct, but if I try out the last line after
> requiring the module
> it does not work as it gives me:
>
> (begin (define (a w / q e) (let* () (+ w 1))) 'a)
>
> The parameter list is not processed any more. (?)
> Is there any way to ensure that this macro will work in the
> same way
> inside and outside the module?
Instead of
(syntax-case args (/)
...)
use
(syntax-case* args (/) module-or-top-identifier=?
...)
where `module-or-top-identifier=?' is provided by `(lib "stx.ss" "syntax")'.
Matthew