[antlr-interest] Character/String Constants

Terence Parr parrt at cs.usfca.edu
Mon Dec 22 09:51:38 PST 2003

On Monday, December 22, 2003, at 09:50 AM, Tom Zagotta wrote:

> Is it possible to define character or string constants?
> For example, if I use '0'..'9' in lots of places, I'd like to define a
> constant called DIGIT.
> I know that in the Lexer I could have a "protected DIGIT: '0'..'9';"
> definition, but this generates an additional member function.  The 
> desire is
> to have this be "inlined" with no member function.
> If this isn't supported in 2.7.2, is it planned for a future release 
> (3?)?

Sorry.  The on-the-fly compiler should inline small functions though.  
It might not however...i do some inlining as a side-effect of auto-left 
factoring and LL-regular analysis for ANTLR 3. :)

Professor Comp. Sci., University of San Francisco
Creator, ANTLR Parser Generator, http://www.antlr.org
Co-founder, http://www.jguru.com
Co-founder, http://www.knowspam.net enjoy email again!
Co-founder, http://www.peerscope.com pure link sharing


Yahoo! Groups Links

To visit your group on the web, go to:

To unsubscribe from this group, send an email to:
 antlr-interest-unsubscribe at yahoogroups.com

Your use of Yahoo! Groups is subject to:

More information about the antlr-interest mailing list