[antlr-interest] Lexer problem - previous token semantic predicate

Gavin Lambert antlr at mirality.co.nz
Fri Apr 4 04:14:29 PDT 2008


At 23:29 4/04/2008, Silvester Pozarnik wrote:
 >The string I want to parse is for example "TRD.2ads". This now
 >generate token sequence (SYS_TRD, REAL_LITERAL) while I need it
 >to generate (SYS_TRD, DOT, IDENTIFIER) sequence (see the
 >fragments from the grammar below).

Can't you just add a dot to the end of SYS_TRD?  Or can that also 
occur without the trailing dot?



More information about the antlr-interest mailing list