[antlr-interest] How can I modify the text of certain tokens in a CommonTokenStream?
Matthew McDole
simucal at gmail.com
Wed Feb 10 22:16:34 PST 2010
So, I should attempt to set the tokens text in the IDENTIFIER
definition in java.g?
I tried something like this:
IDENTIFIER
: IdentifierStart IdentifierPart*
{
$setText("V");
}
;
Which gave me: Java.g:1813:5: attribute is not a token, parameter, or
return value: setText
Is IDENTIFIER not a token?
What am I doing wrong in this case?
More information about the antlr-interest
mailing list