[erlang-questions] Leex - a lexical anaylzer generator, released
Ben Hood
0x6e6562@REDACTED
Fri May 30 02:42:37 CEST 2008
Robert,
On 29 May 2008, at 22:05, Robert Virding wrote:
> As always, now that I have stuck my chin out and released it, report
> bugs and come with comments.
One feature that I miss from other CC toolkits is being able to
declare your regexs to be case insensitive.
Here's an example from a JavaCC grammar:
/* Reserved Words */
TOKEN [IGNORE_CASE] :
{
< NOT : "NOT">
| < AND : "AND">
| < OR : "OR">
| < BETWEEN : "BETWEEN">
| < LIKE : "LIKE">
| < ESCAPE : "ESCAPE">
| < IN : "IN">
| < IS : "IS">
| < TRUE : "TRUE" >
| < FALSE : "FALSE" >
| < NULL : "NULL" >
| < XPATH : "XPATH" >
| < XQUERY : "XQUERY" >
}
I ended having to put patterns in like
between|BETWEEN
to match lower and upper cases alike.
I know that you are bound by what the regexp module can give you though.
Just a thought,
Ben
More information about the erlang-questions
mailing list