[antlr-interest] Escaping single quotes in a lexer

Gavin Lambert antlr at mirality.co.nz
Wed Apr 1 03:32:10 PDT 2009


At 20:57 1/04/2009, Emanuele Gesuato wrote:
 >However i tried your solution, but i've got:
 >     [antlr] ANTLR Parser Generator   Version 2.7.6 
(2005-12-22)
 >1989-2005
 >     [antlr] ..util/parser/SQL.g:54:30: This subrule cannot be
 >inverted.
 >  Only subrules of the form:
 >     [antlr]     (T1|T2|T3...) or
 >     [antlr]     ('c1'|'c2'|'c3'...)
 >     [antlr] may be inverted (ranges are also allowed).
 >     [antlr] Exiting due to errors.

Well, then, go back to the original single-quoted version, since 
that would fit the requirement it's complaining about.



More information about the antlr-interest mailing list