Greetings!

On Thu, 2009-07-02 at 10:35 -0400, Penningroth, Mark wrote:
> I have the following in my grammar:
>
> sqcon
>             : '\'' ( options {greedy=false;} : .)* '\''
> ;
>
> The intent is to get a single text node with everything between the
> sing quotes.
>
> When I parse ‘Los Angeles’  I lose the space .

your sqcon rule is a Parser rule (because it begins with a lower case
letter).

have you tried making it a Lexer rule? by up-casing (at least) the first
letter.

and note that when you make it into a Lexer rule, the text of the token
will include the leading and trailing quotes, so you may need to
substring them away.

Hope this helps
   -jbb



List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org/mailman/options/antlr-interest/your-email-address

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to