[antlr-interest] Using extra channels

Sam Barnett-Cormack s.barnett-cormack at lancaster.ac.uk
Mon Mar 23 11:30:08 PDT 2009


Hi all,

We all (generally) use the default and hidden channels. What if I wanted
there to be another channel which, usually, doesn't get used, but if I
want to tune to it as well I won't get the actual whitespace? Say for
tokens that you mostly won't be interested in, but may want to
programmatically choose to be interested in.

Can I literally just define a new constant, MYCHANNEL, that's an int not
of the same value as HIDDEN or whatever the default one is called, and
use it as I would either of those?

Sam


More information about the antlr-interest mailing list