[antlr-interest] file names and grammar names

Terence Parr parrt at cs.usfca.edu
Wed May 17 17:13:02 PDT 2006


On May 17, 2006, at 5:09 PM, Kay Roepke wrote:
>> Do people think I should force the grammar name (including case)  
>> to be same as filename (with .g suffix)?
>
> Well, personally I have always disliked that but I can see the  
> merit for getting vocabs. If it's clearly spelled out in the docs,  
> it shouldn't really be a problem.
>
> What would lexer grammar file names look like? Foo.lexer.g (like  
> those coming out of combined grammars)?

Good point.  It would have to go like this:

T.g:
grammar T;

TLexer.g:
grammar TLexer;

Ter


More information about the antlr-interest mailing list