]> granicus.if.org Git - clang/commitdiff
Replace copy loop with std::copy.
authorBenjamin Kramer <benny.kra@googlemail.com>
Sun, 5 Apr 2015 18:55:02 +0000 (18:55 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Sun, 5 Apr 2015 18:55:02 +0000 (18:55 +0000)
No functional change intended.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@234123 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/Decl.cpp

index 3efd24f21f9e083225d9e2f7af1a418b88fa451d..69e44573dc6299b6f87e75f8b3d467c3f1f55999 100644 (file)
@@ -1737,8 +1737,7 @@ QualifierInfo::setTemplateParameterListsInfo(ASTContext &Context,
   if (NumTPLists > 0) {
     TemplParamLists = new (Context) TemplateParameterList*[NumTPLists];
     NumTemplParamLists = NumTPLists;
-    for (unsigned i = NumTPLists; i-- > 0; )
-      TemplParamLists[i] = TPLists[i];
+    std::copy(TPLists, TPLists + NumTPLists, TemplParamLists);
   }
 }