[antlr-interest] Intentional?: Can't label (tokens*)
Brendon McLean
antlr at twistedprotein.com
Wed Dec 5 04:53:36 PST 2007
>> postincdec : varref (op='++' | op='--') -> ^
>> (POSTFIX_EXPR $op)
That's what I've done.
>> (I assume you meant ^ before the other parentheses).
Whoops. I did mean that.
> postincdec : varref op=('++' | '--') -> ^(POSTFIX_EXPR $op)
>
> is correct, but an ANTLR bug prevents this usage. Just create an op-
> subrule as workaround.
That's good to know.
Thanks,
Brendon.
More information about the antlr-interest
mailing list