[antlr-interest] Force nodes for grammar rules

Maik Merten maikmerten at gmx.net
Tue Dec 6 09:41:18 PST 2005


> I'm guessing, as "in some cases" is hard to diagnose from afar.... However...

Oh, yeah... right. Sorry for being that fuzzy. We just didn't nail "in
some cases" down yet...

> If you look at the generated code, you should see that with your
> original production, the intermediate node is only added when a
> pr_SelectCaseConstruct is matched.  If you want to have that action
> done for all alternatives, then you need to add an extra set of
> parenthesis around the alternatives:

I guess that explains what's going on. Thank you very much for your help!


Maik


More information about the antlr-interest mailing list