[antlr-interest] Greedy matching to end of line
Robert J. Hansen
rjh at sixdemonbag.org
Fri Jan 28 06:33:22 PST 2011
> Just a thought: depending on what you do with the things after a 'Comment:', you could just match .+ :
Well, I need to pull data out of what comes after the 'Comment:'. If I can find some way to match .+ out to the first newline, and then extract the contents into $value, I'd be a happy camper.
(The grammar I posted has no return values. The actual grammar I use does, since I hook up actions to various rules.)
More information about the antlr-interest
mailing list