diff options
author | Brad King <brad.king@kitware.com> | 2020-06-29 20:45:43 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-06-29 21:23:27 (GMT) |
commit | df6b077625f86e4ec0d534f6cd88f8610c5b8f8a (patch) | |
tree | c2aa4271583dcad49c08570f90f8caf2b97c8451 /Help/manual/cmake.1.rst | |
parent | f2b84d24cfccf49b6332cf3f2ca164fd71ae023e (diff) | |
download | CMake-df6b077625f86e4ec0d534f6cd88f8610c5b8f8a.zip CMake-df6b077625f86e4ec0d534f6cd88f8610c5b8f8a.tar.gz CMake-df6b077625f86e4ec0d534f6cd88f8610c5b8f8a.tar.bz2 |
cmake: Remove broken '--warn-unused-vars' option
This option has been broken since commit b9f9915516 (cmMakefile: Remove
VarUsageStack., 2015-05-17, v3.3.0-rc1~52^2). That commit removed the
check that an initialized variable has actually been used and caused the
option to warn on every variable ever set. This was not caught by the
test suite because the test for the feature only checked that warnings
appear when needed and not that they do not appear when not needed.
The option was never very practical to use. Remove it to avoid the
runtime cost of usage tracking and checks for every variable (which we
were doing even when the option was not used).
Diffstat (limited to 'Help/manual/cmake.1.rst')
-rw-r--r-- | Help/manual/cmake.1.rst | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Help/manual/cmake.1.rst b/Help/manual/cmake.1.rst index 72ecfc7..d5fe34c 100644 --- a/Help/manual/cmake.1.rst +++ b/Help/manual/cmake.1.rst @@ -341,9 +341,9 @@ Options Print a warning when an uninitialized variable is used. ``--warn-unused-vars`` - Warn about unused variables. - - Find variables that are declared or set, but not used. + Does nothing. In CMake versions 3.2 and below this enabled warnings about + unused variables. In CMake versions 3.3 through 3.18 the option was broken. + In CMake 3.19 and above the option has been removed. ``--no-warn-unused-cli`` Don't warn about command line options. |