[antlr-interest] Fwd: Pruning the Parse Tree
Terence Parr
parrt at cs.usfca.edu
Tue Mar 11 11:11:30 PDT 2008
On Mar 11, 2008, at 10:50 AM, Andy Tripp wrote:
> Aaron Armstrong wrote:
>>
>> 2. The default AST is flat. Basically, I get no more information
>> than what the lexer would give me. (I don't know why this is, but
>> ANTLR is not my design).
>>
> I've always thought it was a bit odd that the default AST is flat.
> (Don't bother explaining the reasoning
> to me, I've already heard the explanation, and I still think it's
> odd). At least an option to say
> "make the AST match the parse tree" would be nice, as opposed to
> forcing me to sprinkle
> "^" characters in my grammar.
Uh, making the AST look like a parse tree is, um, a parse tree, which
ANTLR can build for you automatically now no problem.
Ter
More information about the antlr-interest
mailing list