Compile-time AST manipulation API
Frits van Bommel
fvbommel at REMwOVExCAPSs.nl
Sat Nov 24 10:19:11 PST 2007
0ffh wrote:
>
> I wonder: There are quite a few requests floating
> around that would require changes to the D language.
> If the D language is going to be changed, why not go all
> the way and make the change to end all change requests:
> A small compile-time API for AST walking and manipulation.
> I don't just mean macros, but full scale metaprogramming.
> It would even be possible to do refactoring and convert
> the AST back to source from within the language.
> The only problem I really see is that it would require the
> AST structure to be part of the language specification.
...
I think you just reinvented LISP :P.
(Note: all those brackets are in there to encode the AST structure into
the language)
More information about the Digitalmars-d
mailing list