Hi. Currently v3 requires nothing of your tree nodes; all you have to do is 
give me an adapter that says how to create them and navigate them and 
manipulate them. Users can set up ASTLabelType as an option so that $x in 
actions has the user's type instead of plain object.

Sam Harwell and I were talking today about restructuring all of the tree 
interfaces. We're breaking it up into a hierarchy with Tree interface at the 
top. Tree just says you can get a payload, some children, and parent. ParseTree 
and AST split off as sub interfaces. We were thinking that it's pretty silly to 
use simple object when we could require the minimal Tree interface so at least 
code could display or navigate them. The reason I went with plain object 
originally was so people could use any existing object they have, even if they 
only have binary for it. This seems like a fairly extreme example and, in the 
worst case, somebody could wrap those objects so they were suitable for use 
with ANTLR. More than likely, somebody in that situation would simply use 
actions to construct the trees they want. Most trees not built for antlr expect 
everything in the constructor, whereas antlr has to build up the trees 
piecemeal as it parses.

So, does anybody object to ANTLR assuming Tree in the parser if you are 
building trees and then AST in the tree parsers?

Ter

List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org/mailman/options/antlr-interest/your-email-address

-- 
You received this message because you are subscribed to the Google Groups 
"il-antlr-interest" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/il-antlr-interest?hl=en.

Reply via email to