summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-02-18 20:58:07 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-02-18 23:59:19 (GMT)
commitee5bc006ebee898729b81237719106704a2bb38a (patch)
tree9c10960669613e09ba42e39189bda20bcfbba3b5 /Source
parentb3a0c6e08f36efc5f3cd4c1a0d9614a789f91e38 (diff)
downloadCMake-ee5bc006ebee898729b81237719106704a2bb38a.zip
CMake-ee5bc006ebee898729b81237719106704a2bb38a.tar.gz
CMake-ee5bc006ebee898729b81237719106704a2bb38a.tar.bz2
cmGeneratorTarget: Replace set insert algorithm with cmRemoveDuplicates.
Diffstat (limited to 'Source')
-rw-r--r--Source/cmGeneratorTarget.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index a4f099b..44c9e9a 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -528,23 +528,22 @@ cmGeneratorTarget::UseObjectLibraries(std::vector<std::string>& objs,
std::vector<cmSourceFile const*> objectFiles;
this->GetExternalObjects(objectFiles, config);
std::vector<cmTarget*> objectLibraries;
- std::set<cmTarget*> emitted;
for(std::vector<cmSourceFile const*>::const_iterator
it = objectFiles.begin(); it != objectFiles.end(); ++it)
{
std::string objLib = (*it)->GetObjectLibrary();
if (cmTarget* tgt = this->Makefile->FindTargetToUse(objLib))
{
- if (emitted.insert(tgt).second)
- {
- objectLibraries.push_back(tgt);
- }
+ objectLibraries.push_back(tgt);
}
}
+ std::vector<cmTarget*>::const_iterator end
+ = cmRemoveDuplicates(objectLibraries);
+
for(std::vector<cmTarget*>::const_iterator
ti = objectLibraries.begin();
- ti != objectLibraries.end(); ++ti)
+ ti != end; ++ti)
{
cmTarget* objLib = *ti;
cmGeneratorTarget* ogt =