[antlr-interest] specialStateTransition too big for Java (AntLR3)

Ruben Fonseca rubenfonseca at di.uminho.pt
Fri May 4 02:10:47 PDT 2007


Hi!

I'm using AntLR3 to build a PHP parser. I need to get rid of HTML. In
order to do this I implemented a syntatic predicate on my Lexer, to see
if I'm getting HTML or PHP tokens (see an example
http://svn.perl.org/viewcvs/parrot/trunk/languages/plumhead/src/antlr3/Plumhead.g?view=markup )

The problem is that when I generate the Java code with AntLR3, I can't
compile the code, because of the following error:

The code of method specialStateTransition(int, IntStream) is exceeding
the 65535 bytes limit	WebAppViewer/antlr3/php	phpLexer.java	line 3894

I'm guessing my Lexer is too complex or has too many tokens? Does anyone
experienced the same problem before? Thanks for the advice.

Ruben.




More information about the antlr-interest mailing list