The ability to enable absolutely all warnings (-Wall -Wextra -Wyada-yada-yada), and then selectively disable the one's that are not desired. Rather than the opposite.
g++ -c -Wall-all -Wno-unreachable-code -Wno-long-long -Wno-four-char-constants test.cpp -o test.o
That begs the question: what's *not* covered by -W -Wall -Wextra [-ansi -pedantic-errors -Werror]?
There are also some warning flags that are parameterized (-Wstrict-aliasing=#, -Wformat=#), should those be maxed out as well?
Maybe we could call it -WALL? :)
Actually more than that, there are new warnings options each release so really if we have this we will get complaints about warnings options get added. so I am going to close this as won't fix.
Subject: Re: -Wall-all to enable all warnings
> ------- Comment #2 from pinskia at gcc dot gnu dot org 2007-04-14 21:18 -------
> Actually more than that, there are new warnings options each release so really
> if we have this we will get complaints about warnings options get added. so I
> am going to close this as won't fix.
I also don't really see this ever happening because the libstdc++ headers
aren't clean w.r.t. -Weffc++ (if you propose to turn those on too). Even
the man page warns about it. (Vast majority seem to be "non-virtual
destructor in base class" nonsense from my previous attempts.) Even if
fine-grain, source-annotated warning suppressions (__attribute__, etc.)
kick in, *some* of the extra warnings would be a nuisance to work-around,
and extra work for library maintainers. FWIW, -W -Wall has served me
quite well. (-W is -Wextra since 3.4)
*** Bug 47824 has been marked as a duplicate of this bug. ***
*** Bug 66293 has been marked as a duplicate of this bug. ***
*** Bug 53313 has been marked as a duplicate of this bug. ***
Marc, in reply to https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53313#c10
I see there may be value in a -Weverything flag for debugging (and to check if something already warns for a specific testcase). I believe it will be useless for users, but, hey, I'm happy if the description warns users profusely about it, so we don't get a tsunami of reports complaining that "it warns too much".
Your proposed patch (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53313#c5) is probably a good start. It probably doesn't maximize warnings that take several levels (like Wstrict-overflow=) or warnings that internally have several levels (like Wmain).
You should only need to convince Joseph or Dodji.