[antlr-interest] Problems with 'á','é',,....'ñ' recognition
edmont_cu
edmont_cu at yahoo.es
Tue Jun 29 17:06:44 PDT 2004
In the lexer y have the following segment of code:
options
{
charVocabulary ='\3'..'\377'; // allow unicode
....
protected
LETTER : 'a'..'z' | 'A'..'Z'
| 'á' | 'é' | 'í' | 'ó' | 'ú' | 'ñ' | 'ü'
|'Á' | 'É' | 'Í' | 'Ó' | 'Ú' | 'Ñ' | 'Ü';
ID
options
{
testLiterals = true;
}
: ((LETTER (LETTER | DIGIT | '_')*) | (('_')+ LETTER (LETTER
| DIGIT | '_')*));
the problem is that when I make semantic analysis all the IDs miss
the 'á','é',..,'ñ' characters. For example: from "niño" I get "nio".
Any suggestions?
S,
Ediber Montoya Moreira
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/antlr-interest/
<*> To unsubscribe from this group, send an email to:
antlr-interest-unsubscribe at yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list