Hi!
I have a following grammar. Most of the time it works fine. The problem
begins when I try to parse a string like this one:
"test_input OPERATOR another_test_input"
The operator inside quotes is still recognized as a OPERATOR token, while
I'd like it to be recognized as a WORD token that is part of the quote.
grammar test;
start_rule : expr (OPERATOR expr)* EOF;
expr : quote | WORD;
quote : '"' WORD+ '"';
OPERATOR : 'OPERATOR';
WORD : ('a'..'z'|'A'..'Z')+;
Any suggestions?
Thanks for any help,
Bob
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"il-antlr-interest" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/il-antlr-interest?hl=en
-~----------~----~----~----~------~----~------~--~---
List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe:
http://www.antlr.org/mailman/options/antlr-interest/your-email-address