[antlr-interest] Using nonterminals as root node in tree parser rules

Terence Parr parrt at cs.usfca.edu
Tue Jul 11 12:55:54 PDT 2006


On Jul 11, 2006, at 6:32 AM, Ploett, Norbert wrote:

> Hi all,
>
> it seems that this cannot be done in an antlr tree parser:
>
> nonterminal :
>         TERMINAL1
>     |   TERMINAL2
>     ;
>
> rule :
>         #(nonterminal other_stuff)
>     ;

Allowed in v3, but not v2.

Ter



More information about the antlr-interest mailing list