[Mono-dev] System warning removal.

Kornél Pál kornelpal at hotmail.com
Mon Mar 13 15:16:52 EST 2006


If they are invoked from the runtime or somewhere else (either managed or
unmanaged code) I think the best solution is to disable the warnings and put
a comment that describes that it is invoked externally (more intuitive with
the name of the method that invokes it) so that it will not be accidentally
removed when doing cleanup.

If it isn't implemented I think a [MonoTODO] attribute will do.

I agree that warnings are ignored by developers. The reason is I think that
it's quite difficult to notice the warnings. I usually do a full make
("make" in the directory of mono) that only builds modified components but
builds everything involved and all profiles unlike executing "make" in the
directory of the modified component. Errors can be seen as they interrupt
the build process but warnings will remain hidden because they scroll out of
the screen.

Treating warnings as errors could probably solve the problem but that may
lead to simply disabling a lot of warnings either at mcs command line or
using #pragma directives without evaluating whether the warning is
important. And of course disabling warnings at command line possibly hides a
lot of warnings that could be eliminating by using more proper coding


----- Original Message -----
From: "Miguel de Icaza" <miguel at novell.com>
To: "Kornél Pál" <kornelpal at hotmail.com>
Cc: <mono-devel-list at lists.ximian.com>
Sent: Saturday, March 11, 2006 8:13 PM
Subject: Re: [Mono-dev] System warning removal.

> Hey,
>> For the same reason these warnings should not just be disabled. They
>> should
>> be somehow marked that they should be raised by code. So they are not
>> "implemented".
> I have asked Carlos to consider that as a bug report and implement it.
> The problem with having all of these warnings is that developers get
> used to not reading the warnings.  In the end they just evaluate whether
> the assembly compiled without errors.
> So I agree with you that we should fix the code, but in their current
> state they were masking existing bugs.
> There are two warnings left: one I do not know how to fix, the other one
> I want Gonzalo to give his approval, it seems like it might be
> externally invoked.
> Miguel.

More information about the Mono-devel-list mailing list