Use auto in for loop
authorMalcolm Parsons <malcolm.parsons@gmail.com>
Thu, 20 Oct 2016 15:40:34 +0000 (15:40 +0000)
committerMalcolm Parsons <malcolm.parsons@gmail.com>
Thu, 20 Oct 2016 15:40:34 +0000 (15:40 +0000)
llvm-svn: 284737

clang-tools-extra/clang-tidy/modernize/UseDefaultCheck.cpp

index fa2cd75..ce497c8 100644 (file)
@@ -263,7 +263,7 @@ void UseDefaultCheck::check(const MatchFinder::MatchResult &Result) {
         return;
       SpecialFunctionName = "copy constructor";
       // If there are constructor initializers, they must be removed.
-      for (const CXXCtorInitializer *Init : Ctor->inits()) {
+      for (const auto *Init : Ctor->inits()) {
         RemoveInitializers.emplace_back(
             FixItHint::CreateRemoval(Init->getSourceRange()));
       }