[antlr-interest] options and tokens
Shaun Bogan
smbogan at gmail.com
Tue Jan 15 08:40:42 PST 2008
Strangely, that's how I had it before, with options first, then
tokens. I had some commented out code inbetween. It seems removing
the comments fixed it. Odd.
Thanks for the help,
S M Bogan
On Jan 15, 2008 2:10 AM, Shaun Bogan <smbogan at gmail.com> wrote:
> My grammar starts out something like this:
>
> grammar fqs;
>
> tokens {
> IMAGINARY;
> }
>
> options {
> output=AST;
> }
>
> However, I get a an error that options is unexpected. How do I create
> imaginary tokens for my rewrites if I can't use both options and
> tokens? If I flip the order, it always complains about the second
> one. Am I missing something here? This is my first time trying to
> use AST rewrite rules.
>
> Thanks for any help,
> S M Bogan
>
More information about the antlr-interest
mailing list