summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorExpressionNode.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-08-04 17:19:49 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-08-05 16:20:48 (GMT)
commit7c809fa2a675b7e669e76683f73397e38dd22999 (patch)
tree41f75f44f46067e53e5bf76544d476ae8db41c99 /Source/cmGeneratorExpressionNode.cxx
parent6da99de3236fbaeebf6a4fc66f7d68f43a59902f (diff)
downloadCMake-7c809fa2a675b7e669e76683f73397e38dd22999.zip
CMake-7c809fa2a675b7e669e76683f73397e38dd22999.tar.gz
CMake-7c809fa2a675b7e669e76683f73397e38dd22999.tar.bz2
cmGeneratorTarget: Move GetLinkerLanguage from cmTarget.
Diffstat (limited to 'Source/cmGeneratorExpressionNode.cxx')
-rw-r--r--Source/cmGeneratorExpressionNode.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/cmGeneratorExpressionNode.cxx b/Source/cmGeneratorExpressionNode.cxx
index 49fc96b..a86c2bc 100644
--- a/Source/cmGeneratorExpressionNode.cxx
+++ b/Source/cmGeneratorExpressionNode.cxx
@@ -990,6 +990,9 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
assert(target);
+ cmGeneratorTarget* gtgt =
+ context->Makefile->GetGlobalGenerator()->GetGeneratorTarget(target);
+
if (propertyName == "LINKER_LANGUAGE")
{
if (target->LinkLanguagePropagatesToDependents() &&
@@ -1001,7 +1004,7 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
"link libraries for a static library");
return std::string();
}
- return target->GetLinkerLanguage(context->Config);
+ return gtgt->GetLinkerLanguage(context->Config);
}
cmGeneratorExpressionDAGChecker dagChecker(context->Backtrace,
@@ -1128,9 +1131,6 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
}
}
- cmGeneratorTarget* gtgt =
- context->Makefile->GetGlobalGenerator()->GetGeneratorTarget(target);
-
if (!prop)
{
if (target->IsImported()
@@ -1600,7 +1600,7 @@ struct TargetFilesystemArtifactResultCreator<ArtifactPdbTag>
cmGeneratorExpressionContext *context,
const GeneratorExpressionContent *content)
{
- std::string language = target->Target->GetLinkerLanguage(context->Config);
+ std::string language = target->GetLinkerLanguage(context->Config);
std::string pdbSupportVar = "CMAKE_" + language + "_LINKER_SUPPORTS_PDB";