[CM] Snd 10.8
Heinrich Taube
taube at uiuc.edu
Sun Aug 9 05:57:34 PDT 2009
Im expecting to see the "expanding foo macro!" message only one time.
but maybe im confused!
that is i thought the macro got expanded when 'define' did its work,
not when i call the function.
(define-macro (foo . args)
(format #t "expanding foo macro!~%")
`(list , at args))
(define (usefoo a b c)
(foo a b c))
cm> (usefoo 1 2 3)
expanding foo macro!
(1 2 3)
cm> (usefoo 1 2 3)
expanding foo macro!
(1 2 3)
cm> (usefoo 1 2 3)
expanding foo macro!
(1 2 3)
cm>
More information about the Cmdist
mailing list