[antlr-interest] Simple Antlr3 grammar not working in AntlrWorks 1.0b9

Shmuel Siegel ssiegel at finjan.com
Thu Mar 15 08:00:42 PDT 2007


Consider

 

grammar boo;

 

sentence

            :           'abc' 'x' 

            | Item

            ;

            

Item: 'x' '0' '9' ;

 

 

"sentence" doesn't match abcx but does match abcx09. The grammar works
properly if I rewrite "Item" as 

 

Item: 'x09' ;

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20070315/909a0cff/attachment.html 


More information about the antlr-interest mailing list