diff options
Diffstat (limited to 'clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp')
-rw-r--r-- | clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp b/clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp index 3c75246ea34..2a76b304ad5 100644 --- a/clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp +++ b/clang-tools-extra/cpp11-migrate/UseAuto/UseAuto.cpp @@ -26,11 +26,6 @@ int UseAutoTransform::apply(const FileContentsByPath &InputStates, FileContentsByPath &ResultStates) { RefactoringTool UseAutoTool(Database, SourcePaths); - for (FileContentsByPath::const_iterator I = InputStates.begin(), - E = InputStates.end(); - I != E; ++I) - UseAutoTool.mapVirtualFile(I->first, I->second); - unsigned AcceptedChanges = 0; MatchFinder Finder; @@ -42,8 +37,7 @@ int UseAutoTransform::apply(const FileContentsByPath &InputStates, Finder.addMatcher(makeIteratorDeclMatcher(), &ReplaceIterators); Finder.addMatcher(makeDeclWithNewMatcher(), &ReplaceNew); - if (int Result = UseAutoTool.run( - newFrontendActionFactory(&Finder, /*Callbacks=*/ this))) { + if (int Result = UseAutoTool.run(createActionFactory(Finder, InputStates))) { llvm::errs() << "Error encountered during translation.\n"; return Result; } |