[antlr-interest] adding header for lexer class in grammar file
Johannes Luber
jaluber at gmx.de
Fri May 25 01:44:29 PDT 2007
Ifnu _ wrote:
> hi all,
>
> i need to add some header, especially statement to add package, in
> lexer class, i use the default @header{} options but it only appears
> in parser class, but it not appears in lexer class.
> FYI : i use antlr v3.
In a combined gramar, one has to prefix commands with @lexer:: if the
command has to be included in the lexer file.
Best regards,
Johannes Luber
More information about the antlr-interest
mailing list