summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-09-26 13:29:59 (GMT)
committerKitware Robot <kwrobot@kitware.com>2023-09-26 13:30:10 (GMT)
commit78317811551166fb74e7f10a9b211214c2f2748a (patch)
treed2b7d506d689a57d19d401b441967dcd08f4c441 /Source
parent0be496cb5a3bfd643d3c86c59e9ab320f3557cf9 (diff)
parent80df7b174506eb5c7d9db3e65e2ffb59b9e8f16d (diff)
downloadCMake-78317811551166fb74e7f10a9b211214c2f2748a.zip
CMake-78317811551166fb74e7f10a9b211214c2f2748a.tar.gz
CMake-78317811551166fb74e7f10a9b211214c2f2748a.tar.bz2
Merge topic 'lint-genex-empty'
80df7b1745 Linting: Fix empty evaluated genex Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !8833
Diffstat (limited to 'Source')
-rw-r--r--Source/cmCommonTargetGenerator.cxx5
1 files changed, 1 insertions, 4 deletions
diff --git a/Source/cmCommonTargetGenerator.cxx b/Source/cmCommonTargetGenerator.cxx
index 2d6ce98..b13576a 100644
--- a/Source/cmCommonTargetGenerator.cxx
+++ b/Source/cmCommonTargetGenerator.cxx
@@ -330,10 +330,7 @@ std::string cmCommonTargetGenerator::GenerateCodeCheckRules(
auto evaluatedProp = cmGeneratorExpression::Evaluate(
*value, this->GeneratorTarget->GetLocalGenerator(), config,
this->GeneratorTarget, nullptr, this->GeneratorTarget, lang);
- if (!evaluatedProp.empty()) {
- return evaluatedProp;
- }
- return *value;
+ return evaluatedProp;
};
std::string const tidy_prop = cmStrCat(lang, "_CLANG_TIDY");
tidy = evaluateProp(tidy_prop);