diff options
author | Brad King <brad.king@kitware.com> | 2022-05-24 14:08:46 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2022-05-24 14:08:52 (GMT) |
commit | 5ceed2bb28ae3fe8dc4f23c5ea9314c61589e295 (patch) | |
tree | 3d0577ff5ebbb1c71dc2ecf5edb02332570f23cd /Source/cmConditionEvaluator.cxx | |
parent | 9eb81b2f9a115c5fc319ac3679042e6c98a24389 (diff) | |
parent | cb19a634994aec41a070633e2b574bee4a5c5568 (diff) | |
download | CMake-5ceed2bb28ae3fe8dc4f23c5ea9314c61589e295.zip CMake-5ceed2bb28ae3fe8dc4f23c5ea9314c61589e295.tar.gz CMake-5ceed2bb28ae3fe8dc4f23c5ea9314c61589e295.tar.bz2 |
Merge topic 'reduce-policy-eval-scope'
cb19a63499 cmConditionEvaluator: Reduce the scope of the CMP0064 evaluation
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7287
Diffstat (limited to 'Source/cmConditionEvaluator.cxx')
-rw-r--r-- | Source/cmConditionEvaluator.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/Source/cmConditionEvaluator.cxx b/Source/cmConditionEvaluator.cxx index 8df4704..141c4eb 100644 --- a/Source/cmConditionEvaluator.cxx +++ b/Source/cmConditionEvaluator.cxx @@ -531,9 +531,6 @@ bool cmConditionEvaluator::HandleLevel0(cmArgumentList& newArgs, bool cmConditionEvaluator::HandleLevel1(cmArgumentList& newArgs, std::string&, MessageType&) { - const auto policy64IsOld = this->Policy64Status == cmPolicies::OLD || - this->Policy64Status == cmPolicies::WARN; - for (auto args = newArgs.make2ArgsIterator(); args.current != newArgs.end(); args.advance(newArgs)) { @@ -625,7 +622,8 @@ bool cmConditionEvaluator::HandleLevel1(cmArgumentList& newArgs, std::string&, } // does a test exist else if (this->IsKeyword(keyTEST, *args.current)) { - if (policy64IsOld) { + if (this->Policy64Status == cmPolicies::OLD || + this->Policy64Status == cmPolicies::WARN) { continue; } newArgs.ReduceOneArg( |