Browse Source

cmTarget: Use insert instead of std::copy.

insert can reserve() memory in the container, and this is
more-consistent with the rest of CMake now.
Stephen Kelly 10 years ago
parent
commit
3660d063bc
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Source/cmTarget.cxx

+ 2 - 2
Source/cmTarget.cxx

@@ -6058,8 +6058,8 @@ cmTargetInternals::ComputeLinkInterfaceLibraries(
     // The link implementation is the default link interface.
     cmTarget::LinkImplementationLibraries const* impl =
       thisTarget->GetLinkImplementationLibrariesInternal(config, headTarget);
-    std::copy(impl->Libraries.begin(), impl->Libraries.end(),
-              std::back_inserter(iface.Libraries));
+    iface.Libraries.insert(iface.Libraries.end(),
+                           impl->Libraries.begin(), impl->Libraries.end());
     if(thisTarget->PolicyStatusCMP0022 == cmPolicies::WARN &&
        !this->PolicyWarnedCMP0022 && !usage_requirements_only)
       {