This is the mail archive of the
kawa@sourceware.org
mailing list for the Kawa project.
Strange error output for undefined macros inside macros
- From: "Kjetil S. Matheussen" <k dot s dot matheussen at notam02 dot no>
- To: kawa at sources dot redhat dot com
- Date: Fri, 02 Feb 2007 00:31:21 +0100 (CET)
- Subject: Strange error output for undefined macros inside macros
When evaluating the following
"
(define-macro (foo)
(foobar))
(define-macro (foobar)
(display 520))
(foo)
"
I get the following error:
"Argument (#<macro foobar>) to 'apply-to-args' has wrong type
(kawa.lang.Macro) (expected: procedure)"
It took me a long time to figure out that foobar needed to be evaluated
before foo. (of course, I didn't have this small example then. :-) )
Perhaps it would be better to say something like "The foobar macro needs
to be defined before defining foo" instead?