Close
jGuru Forums
Posted By: deniz_toprak Posted On: Monday, November 26, 2007 02:39 AM
I wrote a sample grammar shown below; grammar sample;
mainRule : TWOCHARS ;
NCHAR : 'N' ;
TWOCHARS : 'A' | 'N' ;
Re[2]: what is the trick? why that 3 lines simple grammar does not recognize my character?
Posted By: deniz_toprak Posted On: Friday, November 30, 2007 02:11 AM
Re: what is the trick? why that 3 lines simple grammar does not recognize my character?
Posted By: Anonymous Posted On: Thursday, November 29, 2007 03:02 AM
Hi,
You should remove your NCHAR rule because it conflicts with the TWOCHARS rule.
Writing:
grammar test;
should suffice.