[antlr-interest] got modes?

Terence Parr parrt at cs.usfca.edu
Tue Apr 20 17:18:47 PDT 2010


For v4, added lex modes/states:

lexer grammar L2;

A : 'a' ;
AA : 'aa' ;

mode FOO;

B : 'b' ;
C : 'c' ;

Actions will flip between them (push/pop/flip).
Ter


More information about the antlr-interest mailing list