Re: [Scheme-reports] [wg2] in support of single-arity procedural syntax transformers Alex Shinn 14 May 2011 05:39 UTC

On Fri, May 13, 2011 at 6:14 PM, Eli Barzilay <eli@barzilay.org> wrote:
>
> It's possible to have a world where both systems are optional: either
> you implement neither (so `syntax-rules' is implemented in some
> completely different way, or not at all), one, both, or more.

OK, so you're describing a macro plugin system, where
importing the appropriate macro module would register a
macro object predicate and associated applicator.

Yes, this would not require the syntax-object transformer
system to be in the core.  I think Andy Wingo was suggesting
this be in the core, but let's assume it's a module for now.

The problem is it's still fairly complicated, and theoretical -
there are no systems I know of which do this.  Chicken 3
had pluginable macro systems, but they were basically
mutually exclusive.  We'd need some more work in this
before we could standardize it.  I'm actually interested in
this, so I may hack on it when I get more time.  But in the
meantime it's simpler to just use a wrapper.

The other problem is assuming that the syntax-object
transformers are worthy of the unique position of not
requiring a wrapper.  Why the asymmetry?  I think it's
presumptuous to assume that it, or a deriviate thereof,
is the final step in the evolution of macro systems.

I also think the "single arity is inherently superior to
triple arity" argument is silly.  That's like saying there's
something wrong with vector-set! or substring because
they take three arguments.  It's also irrelevant, because
there could just as easily be alternate macro systems
which also take a single arity signature but use a different
API and semantics from the syntax-object macro
systems.

--
Alex

_______________________________________________
Scheme-reports mailing list
Scheme-reports@scheme-reports.org
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports