[plt-scheme] Where is macroexpand in PLT Scheme?

From: Bill Clementson (bill_clementson at yahoo.com)
Date: Tue Nov 11 16:00:32 EST 2003

--- John Clements <clements at brinckerhoff.org> wrote:
> Ha!  Funny, just this morning I was thinking that
> perhaps 'Check 
> Syntax' should be disabled in the Expander language.
>  No, you click on 
> Execute.  That is, the Expander language level is
> one that elaborates 
> the user's code into code that expands and displays
> itself.


The expansion seems to do an "expand" rather than an
"expand-to-top-level". I've found that
"expand-to-top-level" is more useful to me in
understanding what the macro is doing, why did you
choose to use "expand" instead? What type of
information is shown in "expand" that you feel would
be useful in understanding a macro expansion? (I just
want to understand the rationale as I played around
with both and I couldn't understand the value of the
output produced by "expand". I saw that it might be
useful for the DrScheme tool implementer, but I
couldn't see it's value for the "normal" macro writer.
For the normal macro writer, I would have thought that
"expand-to-top-level" was more useful)

Also, the "General Info" on the right-hand side of the
expansion always seems to have a colorer.ss structure
as the source. What is the significance of this? 


> > Stepper is a neat tool - it's unfortunate that it
> only
> > works at the lower language levels. Are you aware
> of
> > any programs that are doing interesting things
> with
> > syntax objects other than stepper? I would like to
> see
> > some good examples of how people are using this
> > language feature.
> Very unfortunate, I agree.  Mea Culpa.

Are you planning to expand (pun intended :) )
stepper's functionality to include support for the
more advanced language levels at some stage?

> Yes, syntax properties are used by a variety of
> tools.  grep for 
> 'syntax-property' in the collects tree (and prune
> out the 'doc' 
> collection), and you'll see hits in the compiler,
> the teachpack code, 
> the Check Syntax tool, the stacktrace/errortrace,
> the language level 
> implementations, the contract library, and all over
> the stepper.

Thanks, I'll have to do some exploring.

Bill Clementson

Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard

Posted on the users mailing list.