public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug driver/44210]  New: Extended warning control: like -Wevery -show-warnings
@ 2010-05-20 11:46 eric dot estievenart at free dot fr
  2010-05-20 13:31 ` [Bug driver/44210] " redi at gcc dot gnu dot org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: eric dot estievenart at free dot fr @ 2010-05-20 11:46 UTC (permalink / raw)
  To: gcc-bugs

As I always wonder if my compiler could help me find more bugs,
and the list of warnings I enable tend to be very long,
and -Wall is not enough for me...

(This bug certainly depends on #44209: "Some warnings are not linked to
diagnostics options")

It would be great to have the following options:
(I really don't care for their names if you have better suggestions;
I focus on the functionality)

-Wevery:  would enable all warnings known to gcc 
================================================
This would allow reducing this (infamous) list:
-W -Wall -Wextra -Wstrict-aliasing=2 -Wfloat-equal -Wundef -Wconversion
-Winline -Wmissing-field-initializers -Wshadow -Wcast-align -Wformat=2
-Wsequence-point -Woverloaded-virtual
(I never know which one is enabled by -W, -Wall, -Wextra...)
to a single -Wevery with a few -Wno-XXXXXX

-show-warnings:  would show the enabled warnings 
================================================
An example usage would be:
$ gcc -c somefile.c -Wall -Werror -Wno-error=reorder -Wno-unused-function
                    ..... -show-warnings
status  name             from
------------------------------------------------
ERROR   address          -Wall -Werror
warn    reorder          -Wall -Werror -Wno-error=reorder
-       unused-function  -Wno-unused-function
-       clobbered        (would be enabled by -Wextra)
...
------------------------------------------------
372 known warnings, 300 shown, 297 as errors  (muted: 72)

If the team is interested, I'll consider providing a patch.


-- 
           Summary: Extended warning control: like -Wevery -show-warnings
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: driver
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: eric dot estievenart at free dot fr
 GCC build triplet: does not apply
  GCC host triplet: does not apply
GCC target triplet: does not apply


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44210


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-05-22  0:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-20 11:46 [Bug driver/44210] New: Extended warning control: like -Wevery -show-warnings eric dot estievenart at free dot fr
2010-05-20 13:31 ` [Bug driver/44210] " redi at gcc dot gnu dot org
2010-05-20 15:07 ` eric dot estievenart at free dot fr
2010-05-20 16:15 ` [Bug other/44210] " redi at gcc dot gnu dot org
2010-05-20 17:04 ` manu at gcc dot gnu dot org
2010-05-21 18:00 ` eric dot estievenart at free dot fr
2010-05-22  0:32 ` manu at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).