[plt-scheme] define-syntax question
> I'm doing a little work in version 103 with define-syntax and I'm having a
> little trouble. Here's my example and the results.
> [...]
> (define-syntax d2
> (syntax-rules ()
> ((_ (fun arg1 ...) pgm ...)
> 'multi-args)
> ((_ (fun arg1 . rest) pgm ...)
> 'improper-list)
> ))
> [...]
> > (d2 (x a . b) a)
> andmap: expects type <proper list> as 2nd argument, given: (a . b); other
> arguments were: #<procedure>
This looks to me like a bug in 103's `syntax-rules'.
In my copy of plt/collects/mzlib/synruler.ss, replacing `pair?' with
`list?' on line 278 seems to fix the problem.
Matthew