https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90463
Bug ID: 90463
Summary: Documentation: -Wunused not listed among the options
enabled by -Wall
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: gennaro.prota+gccbugzilla at gmail dot com
Target Milestone: ---
The documentation for the -Wunused option says
"note that -Wall implies -Wunused"
however the list of options enabled by -Wall does not include -Wunused (only
some of the various -Wunused-xyz options).
With g++ 7.4.0 under Cygwin:
g++ -Wall -Q --help=warnings | fgrep unused
-Wunused [enabled]
-Wunused-but-set-parameter [disabled]
-Wunused-but-set-variable [enabled]
-Wunused-const-variable
-Wunused-const-variable= 1
-Wunused-dummy-argument [disabled]
-Wunused-function [enabled]
-Wunused-label [enabled]
-Wunused-local-typedefs [enabled]
-Wunused-macros [disabled]
-Wunused-parameter [disabled]
-Wunused-result [enabled]
-Wunused-value [enabled]
-Wunused-variable [enabled]