[antlr-interest] Lexer lookahead problems
Peter Kronenberg
PKronenberg at technicacorp.com
Wed Apr 6 05:39:02 PDT 2005
I'm trying to write a lexer for expressions which accepts both character
and symbol comparisons, e.g., =, >, <, as well as EQ, GT, LT.
But in the lexer reports nondeterminism between EQ and my IDENT rule,
naturally. Increasing the lookahead doesn't seem to help. Is there a
way to fix this?
EQ : "=" | "EQ";
IDENT: ('a'..'z' | 'A'..'Z') ('a'..'z' | 'A'..'Z' | '0'..'9' | '_'
| '$')*;
Peter Kronenberg
Software Engineer
(703) 885-1222
pkronenberg at technicacorp.com
The information contained in this transmission may contain privileged and confidential information. It is intended only for the use of the person(s) named above. If you are not the intended recipient, you are hereby notified that any review, dissemination, distribution or duplication of this communication is strictly prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. Technica Corporation does not represent this e-mail to be free from any virus, fault or defect and it is therefore the responsibility of the recipient to first scan it for viruses, faults and defects. To reply to our e-mail administrator directly, please send an e-mail to postmaster at technicacorp.com. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20050406/4e4e4d1e/attachment.html
More information about the antlr-interest
mailing list