If I use -Wextra option with gcc, I don't need to use -Wall?

Viewed 70

Does -Wextra also enable -Wall, and does -Wall also enable -W in GCC?

1 Answers

-Wextra is a replacement to the old -W flag. It enables some extra warnings which are not enabled by -Wall, and does not enable -Wall by itself - if you want both, you'll have to use -Wall -Wextra.

Related