[plt-scheme] Help with understanding how to reuse macro data

From: Grant Rettke (grettke at acm.org)
Date: Sun Jan 4 23:10:40 EST 2009

On Sat, Jan 3, 2009 at 4:03 PM, Joe Marshall <jmarshall at alum.mit.edu> wrote:
> On Fri, Jan 2, 2009 at 4:25 PM, Grant Rettke <grettke at acm.org> wrote:
>> Does the fact that I'm taking this data and compiling it down to
>> something trivial disqualify it? What if it were being compiled into a
>> compelling "thing" written in Scheme?
> Here's the logic behind my opinion....

I see. Thanks for elaborating.

>> I see now, there is a clear delineation: once scenario is parsing data
>> differently (with different functions or classes) and another is
>> generating code differently based on the input. The problem I am
>> trying to solve is the former, macros don't make sense.
>> That said, if they did make sense, how would one go about reusing that
>> data definition?
> I have seen *very* few cases where this would make sense, but I think
> what you would want to do is write meta-macros that wrap the macros
> with a let-syntax form that does the base macro processing.  It'd be one
> of those hairballs that Al* Petrofsky is so fond of.

I forgot about an example in TSPL that does something like this:


Posted on the users mailing list.