[antlr-interest] [newbie] AST Rewriting

cpgarg10 cpgarg10 at gmail.com
Fri Mar 30 03:24:34 PDT 2012

Hi Eric,

I think i am also in same situation. 

Actually my problem is to write a parser for some language say X so that i
can retrieve the info written in that language X. Using ANTLR i could
generate the lexer/parser automatically and i could also the AST for input.
Now i think i have to walk the AST and get the info associated with nodes
and build internal data structure. But my problem is i am getting all the
nodes in sequence. I initially thought, i will get AST in tree structure
[Multi level]. Where extracting info would be straight forward.

But here it seems that i need to do some work on AST walker. I read about
adapter things quite a lot on ANTLR mailing list. But could not understood
adapter much. It is something related to AST walker, can it make my life
easier. I mean, can i use adapter in AST walk. or something like it. 

Your comments are welcome.


View this message in context: http://antlr.1301665.n2.nabble.com/newbie-AST-Rewriting-tp7385275p7420947.html
Sent from the ANTLR mailing list archive at Nabble.com.

More information about the antlr-interest mailing list