[antlr-interest] Re: Problem with x: (A)(B)? ;
dotlessbraille
easjolly at ix.netcom.com
Wed Feb 25 10:26:02 PST 2004
I really appreciate your trying to help but request you to please
look at the generated Java. I understand that ANTLR will put in a
test for an EOF if I don't put one in. However, this test is at the
highest level of alternatives.
The problem I am encountering is that ANTLR interprets the (B)? as
requiring either a B or an EOF directly after the A. In other
words, it won't handle the case where there are two A's. It works
fine if I use x:A(B)* which isn't what I want, however.
startRule :
(x:A(B)?
|b:B
|eof:EOF
);
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/antlr-interest/
<*> To unsubscribe from this group, send an email to:
antlr-interest-unsubscribe at yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list