summaryrefslogtreecommitdiffstats
path: root/Modules/CheckCCompilerFlag.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-09-21 14:28:47 (GMT)
committerBrad King <brad.king@kitware.com>2020-09-21 14:33:19 (GMT)
commitd46590910c2c3c9dfd79dfc4e81ba91eb1ea6d8d (patch)
tree5ded4027ef9360772fbbaeb1e438e263396491c4 /Modules/CheckCCompilerFlag.cmake
parent566e96d42db35e2c88ceb5d0f3de49736295c496 (diff)
downloadCMake-d46590910c2c3c9dfd79dfc4e81ba91eb1ea6d8d.zip
CMake-d46590910c2c3c9dfd79dfc4e81ba91eb1ea6d8d.tar.gz
CMake-d46590910c2c3c9dfd79dfc4e81ba91eb1ea6d8d.tar.bz2
Check*CompilerFlag: Do not set result as a normal variable too
Refactoring in commit cb984c6627 (Check*CompilerFlag: Modernize modules, 2019-12-09, v3.17.0-rc1~320^2) accidentally left the result set as a normal variable in addition to as a cache entry. This is not specified by the documentation, and is not the behavior in CMake 3.16 and below. Fixes: #21207
Diffstat (limited to 'Modules/CheckCCompilerFlag.cmake')
-rw-r--r--Modules/CheckCCompilerFlag.cmake1
1 files changed, 0 insertions, 1 deletions
diff --git a/Modules/CheckCCompilerFlag.cmake b/Modules/CheckCCompilerFlag.cmake
index 6d65313..1452b51 100644
--- a/Modules/CheckCCompilerFlag.cmake
+++ b/Modules/CheckCCompilerFlag.cmake
@@ -54,5 +54,4 @@ function(check_c_compiler_flag _flag _var)
foreach(v IN LISTS _locale_vars)
set(ENV{${v}} ${_locale_vars_saved_${v}})
endforeach()
- set(${_var} "${${_var}}" PARENT_SCOPE)
endfunction()