On 10/25/2012 04:53 AM, Amos Jeffries wrote:
> Are there any other C++ relevant warnings people think we should test for?
I would add -Woverloaded-virtual to the tests:
-Woverloaded-virtual (C++ and Objective-C++ only)
Warn when a function declaration hides virtual functions from a
base class.
It would be good to investigate these as well:
-Wsign-promo (C++ and Objective-C++ only)
Warn when overload resolution chooses a promotion from unsigned or
enumerated type to a signed type, over a conversion to an unsigned
type of the same size. Previous versions of G++ would try to
preserve unsignedness, but the standard mandates the current
behavior.
-Wextra
This enables some extra warning flags that are not enabled by
-Wall.
-Wextra enables some of the useful tests which have no corresponding -W
option but may drag in too much noise.
There are probably other useful tests. I only searched for those related
to C++ and not enabled by -Wall but it is easy to miss tests when
looking through the manual page.
HTH,
Alex.
Received on Thu Oct 25 2012 - 15:50:23 MDT
This archive was generated by hypermail 2.2.0 : Thu Oct 25 2012 - 12:00:08 MDT