About Go, D module naming

Jonathan M Davis jmdavisProg at gmx.com
Fri Dec 21 20:20:03 PST 2012


On Friday, December 21, 2012 14:25:28 Walter Bright wrote:
> On 12/21/2012 1:40 PM, Jonathan M Davis wrote:
> > I would point out that -w does exactly that thanks to conditional
> > compilation and compile-time introspection.
> 
> I know, and there are threads here where I opposed warnings very strongly.

I tend to agree that warnings were a bad idea and that they should never have 
been introduced, if nothing else, because I don't think that it's ever good 
practice to leave warnings in your code, making them almost the same as errors 
anyway. However, what every other compiler I have ever seen does is what the
-wi flag does - always print warnings but never have them affect compilation. If 
we're going to have them, I would expect that that's how they would always 
work (so, no -wi or -w flags would be required, and warnings would never affect 
compilation). The -w flag just makes things worse, because of how it affects 
what will and won't compile.

It may be too late to change it now, but if we could, I would think that it 
would be best to make -wi the default behavior and deprecate both -w and -wi. 
Then we'd function like pretty much every other compiler on the planet, and we 
wouldn't have issues with compiler flags affecting conditional compilation.

- Jonathan M Davis


More information about the Digitalmars-d mailing list