--
[0] - even if by ignoring them, when you're absolutely sure what you're doing.
--
[0] - even if by ignoring them, when you're absolutely sure what you're doing.
-Wall -Wextra -Werror
If these options are set before you write any code, then these problems don't arise.Also IMO you often want to explicitly disable a few of those from -Wall and -Wextra -- Looking at the last c++ project I wrote, I turned off a few things like `-Wno-unused-parameter` for example.
[0]: http://blog.schmorp.de/2016-02-27-tidbits-for-the-love-of-go...
As you get further into a project you tend to need subtler tools. But for the rough work when starting out, my preference is to be stricter, which can be relaxed as necessary, rather than starting out lax and reaching a point where tightening becomes Sisyphean.
-Weverything
Which does actually turn on all warnings (so you'll probably want to add things like -Wno-unused -Wno-padded).Under gcc, '-Wall -Wextra -Wpedantic' does not enable all warnings. There are still more than 40 flags you have to give if you really want all of them.
The reason why boggles my mind to this day.