[antlr-interest] TreeParser efficiency: Can TreeParsers ignore arbitary subtrees?

micheal_jor open.zone at virgin.net
Tue May 13 05:11:13 PDT 2003


Hi,

I just wondered if it is possible to generate TreeParsers that ignore 
(i.e. do not "visit") the nodes in arbitary subtrees. 

I have an AST in which only a few nodes have attributes I am 
interested in processing with a TreeParser. Because every TreeParser 
grammar describes the whole tree(?), all nodes are still visited even 
if no action code exists to be executed.

Is it possible to effectively say in the TreeParser grammar "I won't 
be doing anything in this node/subtree so don't even generate code to 
visit it?

Cheers,

Micheal



 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 




More information about the antlr-interest mailing list