[antlr-interest] Re: Getting at the token text in a parser
lgcraymer
lgc at mail1.jpl.nasa.gov
Mon Mar 1 21:42:28 PST 2004
Take another look. It's under the heading "AST Action Translation"
--Loring
--- In antlr-interest at yahoogroups.com, "offline314159" <offline at s...>
wrote:
> It looks like the problem is in the fact that it's a parser rule
> instead of a token - i can use that syntax just fine with token
> references, and i can set a return value on my parser rules and assign
> from them, but that's about it. And it's kind of a pain, but so be it.
>
> However, that "precede with '#'" trick works, or so it appears... is
> it just me or should that be somewhere in the docs? (Since it isn't
> anywhere i can see)
>
> --- In antlr-interest at yahoogroups.com, "lgcraymer" <lgc at m...> wrote:
> > Looks like you haven't set buildAST=true in your parser options
> > section. Also, use the #label syntax (#grp instead of grp)--antlr
> > name "mangling" could change.
> >
> > --Loring
> >
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/antlr-interest/
<*> To unsubscribe from this group, send an email to:
antlr-interest-unsubscribe at yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list