[antlr-interest] Buglet in literal escaping

Johannes Luber JALuber at gmx.de
Thu Feb 12 08:06:13 PST 2009


> Using '\\"' as a literal in an ANTLR grammar causes ANTLRv3.1.1 to emit:
>   match("\\"")
> which is an unterminated string constant.  Oops!

That's no bug, ANTLR does exactly what it is supposed to do. I think you want to use "\\\"" instead.

Johannes
>  --scott
> 
> -- 
>                          ( http://cscott.net/ )
> 
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe:
> http://www.antlr.org/mailman/options/antlr-interest/your-email-address

-- 
Jetzt 1 Monat kostenlos! GMX FreeDSL - Telefonanschluss + DSL 
für nur 17,95 Euro/mtl.!* http://dsl.gmx.de/?ac=OM.AD.PD003K11308T4569a


More information about the antlr-interest mailing list