diff options
author | Brad King <brad.king@kitware.com> | 2014-06-16 13:55:20 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-06-23 13:17:06 (GMT) |
commit | 9f3ed029ce830f0395e102258758a4b3680e5d0f (patch) | |
tree | f2d59ee39894ad998e94bad38d7cc6e8e3458557 /Source/cmGeneratorExpressionEvaluator.cxx | |
parent | 6f0951af011d28366cf31ff621238f026cb8d895 (diff) | |
download | CMake-9f3ed029ce830f0395e102258758a4b3680e5d0f.zip CMake-9f3ed029ce830f0395e102258758a4b3680e5d0f.tar.gz CMake-9f3ed029ce830f0395e102258758a4b3680e5d0f.tar.bz2 |
cmTarget: Constify GetTransitivePropertyTargets results
Populate a vector of "cmTarget const*" instead of "cmTarget*".
Diffstat (limited to 'Source/cmGeneratorExpressionEvaluator.cxx')
-rw-r--r-- | Source/cmGeneratorExpressionEvaluator.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/Source/cmGeneratorExpressionEvaluator.cxx b/Source/cmGeneratorExpressionEvaluator.cxx index cefdd63..3dee601 100644 --- a/Source/cmGeneratorExpressionEvaluator.cxx +++ b/Source/cmGeneratorExpressionEvaluator.cxx @@ -799,7 +799,8 @@ static const char* targetPropertyTransitiveWhitelist[] = { #undef TRANSITIVE_PROPERTY_NAME -std::string getLinkedTargetsContent(const std::vector<cmTarget*> &targets, +std::string getLinkedTargetsContent( + const std::vector<cmTarget const*> &targets, cmTarget const* target, cmTarget const* headTarget, cmGeneratorExpressionContext *context, @@ -810,7 +811,7 @@ std::string getLinkedTargetsContent(const std::vector<cmTarget*> &targets, std::string sep; std::string depString; - for (std::vector<cmTarget*>::const_iterator + for (std::vector<cmTarget const*>::const_iterator it = targets.begin(); it != targets.end(); ++it) { @@ -847,12 +848,12 @@ std::string getLinkedTargetsContent(const std::vector<std::string> &libraries, cmGeneratorExpressionDAGChecker *dagChecker, const std::string &interfacePropertyName) { - std::vector<cmTarget*> tgts; + std::vector<cmTarget const*> tgts; for (std::vector<std::string>::const_iterator it = libraries.begin(); it != libraries.end(); ++it) { - if (cmTarget *tgt = context->Makefile->FindTargetToUse(*it)) + if (cmTarget const *tgt = context->Makefile->FindTargetToUse(*it)) { tgts.push_back(tgt); } @@ -1082,7 +1083,7 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode cmStrCmp(propertyName)) != transEnd) { - std::vector<cmTarget*> tgts; + std::vector<cmTarget const*> tgts; target->GetTransitivePropertyTargets(context->Config, headTarget, tgts); if (!tgts.empty()) |