[plt-scheme] A question on "expand"

From: Chris Wright (caw at cs.mu.oz.au)
Date: Tue Nov 12 00:18:53 EST 2002

I'm currently in the middle of getting macros all wrong;)
So, I'm trying to "see what they look like" by using "expand"

  (define-macro t
     (lambda (args)
       `(apply + ,args)))


(useless --- I know)

 > (t ' (1 2))
3

(Yipee!)

but I want to see the expansion:

 > (expand (t '(1 2)))
#<syntax>
  (expand-to-top-form (t '(1 2)))
#<syntax>

Terrific :(

How do I "see" the expansion?


thanks


Chris

Dr Chris Wright
Medical Director, ICU
Monash Medical Centre
Clayton VIC 3168



Posted on the users mailing list.