On 10/13/2010 01:29 PM, Leonardo K. Shikida wrote: > Hi > > This is something stupid, I guess. I have a grammar like this below > and I would like to know why > > "1+1-1" works > > and > > "1-1+1" does not work (NoViableAltException)
NoViableAltException is thrown in your stat rule when it can't predict an INT, ID, (, or NEWLINE in the lookahead. Does your test case end in a NEWLINE? > Thanks > > Leo K. -- Kevin J. Cummings [email protected] [email protected] [email protected] Registered Linux User #1232 (http://counter.li.org) 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.
