diff options
author | Brad King <brad.king@kitware.com> | 2018-09-06 16:49:34 -0400 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2018-09-07 09:23:43 -0400 |
commit | 1b57f49586afc9e8663d5e146732b1cd0597e7ef (patch) | |
tree | 3754c4403d6b5cc3f5e6b2543f6e1f394dc92ea7 /Source/cmServerProtocol.cxx | |
parent | bea390e9bd68e1aa7d86b6aef7384f502c39068c (diff) | |
download | cmake-1b57f49586afc9e8663d5e146732b1cd0597e7ef.tar.gz |
genex: Simplify cmGeneratorExpressionInterpreter
All callers were constructing with a non-empty target name using the
target whose pointer was passed anyway. Drop this argument. Simplify
logic accordingly. Re-order constructor arguments to match the
cmCompiledGeneratorExpression::Evaluate arguments.
Also remove unnecessary getters.
Diffstat (limited to 'Source/cmServerProtocol.cxx')
-rw-r--r-- | Source/cmServerProtocol.cxx | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Source/cmServerProtocol.cxx b/Source/cmServerProtocol.cxx index af4b466386..231cacb0ce 100644 --- a/Source/cmServerProtocol.cxx +++ b/Source/cmServerProtocol.cxx @@ -722,8 +722,8 @@ static void PopulateFileGroupData( ? languageDataMap.at(kInterfaceSourcesLanguageDataKey) : languageDataMap.at(fileData.Language); cmLocalGenerator* lg = target->GetLocalGenerator(); - cmGeneratorExpressionInterpreter genexInterpreter( - lg, target, config, target->GetName(), fileData.Language); + cmGeneratorExpressionInterpreter genexInterpreter(lg, config, target, + fileData.Language); std::string compileFlags = ld.Flags; const std::string COMPILE_FLAGS("COMPILE_FLAGS"); @@ -817,7 +817,7 @@ static Json::Value DumpSourceFilesList( auto targetProp = target->Target->GetProperty("INTERFACE_SOURCES"); if (targetProp != nullptr) { cmGeneratorExpressionInterpreter genexInterpreter( - target->GetLocalGenerator(), target, config, target->GetName(), ""); + target->GetLocalGenerator(), config, target); auto evaluatedSources = cmsys::SystemTools::SplitString( genexInterpreter.Evaluate(targetProp, "INTERFACE_SOURCES"), ';'); @@ -977,8 +977,7 @@ static void CreateInterfaceSourcesEntry( LanguageData& ld = languageDataMap[kInterfaceSourcesLanguageDataKey]; ld.Language = ""; - cmGeneratorExpressionInterpreter genexInterpreter(lg, target, config, - target->GetName(), ""); + cmGeneratorExpressionInterpreter genexInterpreter(lg, config, target); std::vector<std::string> propertyValue; GetTargetProperty(genexInterpreter, target, "INTERFACE_INCLUDE_DIRECTORIES", propertyValue); |