[antlr-interest] Faster expression parsing

James Mansion james at mansionfamily.plus.com
Fri Aug 29 12:56:46 PDT 2008


Terence Parr wrote:
> nope... how can I be sure you do not want those elided constructs?
>
> foo -> foo
>
> I suppose I could get rid of, but two compilers really get rid of a=a;?
OK I mis-wrote, I meant just dropping the production side.  You seemed
to imply that its presence slows things up.

And I think a=a; is fair game if you know that operator= has no side 
effects.
Which is true in Java, and you can define to be true for other antlr parse
tree constructs.

Or have I missed something obvious?  (Been a long 4 day week, somehow)

James



More information about the antlr-interest mailing list