[antlr-interest] file names and grammar names

Micheal J open.zone at virgin.net
Fri May 19 05:34:20 PDT 2006


Ric,

> > Do people think I should force the grammar name (including 
> case) to be 
> > same as filename (with .g suffix)?
> 
> Dunno. I don't like the force thingy ;) Including case might 
> give problem on filesystems not supporting (or faking) case 
> sensitivity. Maybe a case if it's not broken don't fix it?

Perhaps it was "broken" and we just got used to it?  ;-)

Anyhooo, it was part of the reason I stopped the VS.NET [codegen]
integration for ANTLR way back when. The multiple [possibly unrelated]
language processors from one grammar file issue was another. VS.NET just
couldn't handle that with any of it's straightforward-integration options.

I like the flexibility even though I most often use a
one-langauge-processor-per-file scheme. Perhaps we could consider providing
a tiny support library that can be used to determine the output files for a
given grammar file. This library would be distinct from the runtime library.
It is really meant to be used by/with build tools and could be available in
Java, C (or perhaps C++) and C# to cover most build platforms.

I don't much like Java's inflexible naming scheme but, I'd like to see a
Nant/MSBuild task too.


Micheal



More information about the antlr-interest mailing list