[antlr-interest] LT(0)

Braden McDaniel braden at endoframe.com
Sun Apr 6 11:34:36 PDT 2003


On Sun, 2003-04-06 at 13:10, Albert Huh wrote:
> You could just save a reference to the lexer within your parser.  That's how I go about getting the line number information from the lexer.
>  
> Any thoughts on that approach?

I'd have to define my own constructor. That's something I've managed to
avoid doing so far, and I'd prefer to continue to avoid it.

There's only one spot in my grammar where using named the terminals
wasn't a convenient approach. And there I think I'm content to settle
for using LT(1).

-- 
Braden McDaniel                           e-mail: <braden at endoframe.com>
<http://endoframe.com>                    Jabber: <braden at jabber.org>


 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 




More information about the antlr-interest mailing list