[antlr-interest] Can someone please explain

Silvain Piree s.piree at enneya.com
Thu Jun 20 23:51:03 PDT 2002


Hi,

I'm getting nondeterminism warnings on my grammar but
I don't understand why.

Following rule does not cause a problem when using k=5:

rule:    A B C D E       |     A B C D F   ;

But, when I make the B optional then I get a nondeterminism
warning regardless of lookahead 'k':

rule:    A (B)? C D E       |     A (B)? C D F   ;

Any suggestions would be much appreciated,

Silvain




 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 



More information about the antlr-interest mailing list