[antlr-interest] Bug: String constant is too big in Parser generated by ANTLR v4

Christian chwchw at gmx.de
Wed Jan 11 17:22:20 PST 2012


Hi everybody and especially Terence!

I get the following error message from Eclipse after ANTLR v4 has
generated the parser in Java:

    The type generates a string that requires more than 65535 bytes to
encode in Utf8 format in the constant pool.

I think this is due to your _serializedATN string. Could you dynamically
build it with a StringBuilder perhaps? If you fix it, apply the same
solution to the lexer please.

Regards,
Christian


More information about the antlr-interest mailing list