[antlr-interest] case in-sensitive literals

Andrew Deren andrew at adersoftware.com
Fri Mar 14 07:56:20 PST 2003


I thought I had 2.7.2. I looked at the install.html and it says 2.7.2.
In my grammar I have "and" lower case, and it would only accept lower case.
Thanks.

----- Original Message -----
From: <mzukowski at yci.com>
To: <antlr-interest at yahoogroups.com>
Sent: Friday, March 14, 2003 9:35 AM
Subject: RE: [antlr-interest] case in-sensitive literals


> Try putting "and" in instead.  I think antlr normalizes to lower case.  I
> thought this was a bug that was fixed in 2.7.2, is that what you are
using?
>
> Monty
>
> -----Original Message-----
> From: Andrew Deren [mailto:andrew at adersoftware.com]
> Sent: Thursday, March 13, 2003 4:53 PM
> To: antlr-interest at yahoogroups.com
> Subject: [antlr-interest] case in-sensitive literals
>
>
> I need my literals in grammar to not be case sensitive.
> I set the option: caseSensitive=false in lexer, and
> caseSensitiveLiterals=false but it still doesn't work.
> What I'm trying to accomplish is to have in parser:
> andExpr : otherExpr "and" otherExpr
> but have it work for either "and" or "AND" or any other combination.
> I have more of those literals (or, is, not, etc)
> It looks like when I put "AND" in the program, lexer matches Token.ID
> Thanks,
> Andrew
>
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>



 

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



More information about the antlr-interest mailing list