diff options
Diffstat (limited to 'clang/unittests/Tooling/ToolingTest.cpp')
-rw-r--r-- | clang/unittests/Tooling/ToolingTest.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/clang/unittests/Tooling/ToolingTest.cpp b/clang/unittests/Tooling/ToolingTest.cpp index f9f4de3..447b997 100644 --- a/clang/unittests/Tooling/ToolingTest.cpp +++ b/clang/unittests/Tooling/ToolingTest.cpp @@ -63,7 +63,7 @@ class FindTopLevelDeclConsumer : public clang::ASTConsumer { TEST(runToolOnCode, FindsNoTopLevelDeclOnEmptyCode) { bool FoundTopLevelDecl = false; EXPECT_TRUE( - runToolOnCode(new TestAction(llvm::make_unique<FindTopLevelDeclConsumer>( + runToolOnCode(new TestAction(std::make_unique<FindTopLevelDeclConsumer>( &FoundTopLevelDecl)), "")); EXPECT_FALSE(FoundTopLevelDecl); @@ -103,14 +103,14 @@ bool FindClassDeclX(ASTUnit *AST) { TEST(runToolOnCode, FindsClassDecl) { bool FoundClassDeclX = false; EXPECT_TRUE( - runToolOnCode(new TestAction(llvm::make_unique<FindClassDeclXConsumer>( + runToolOnCode(new TestAction(std::make_unique<FindClassDeclXConsumer>( &FoundClassDeclX)), "class X;")); EXPECT_TRUE(FoundClassDeclX); FoundClassDeclX = false; EXPECT_TRUE( - runToolOnCode(new TestAction(llvm::make_unique<FindClassDeclXConsumer>( + runToolOnCode(new TestAction(std::make_unique<FindClassDeclXConsumer>( &FoundClassDeclX)), "class Y;")); EXPECT_FALSE(FoundClassDeclX); @@ -135,7 +135,7 @@ TEST(newFrontendActionFactory, CreatesFrontendActionFactoryFromType) { struct IndependentFrontendActionCreator { std::unique_ptr<ASTConsumer> newASTConsumer() { - return llvm::make_unique<FindTopLevelDeclConsumer>(nullptr); + return std::make_unique<FindTopLevelDeclConsumer>(nullptr); } }; @@ -207,7 +207,7 @@ struct VerifyEndCallback : public SourceFileCallbacks { } void handleEndSource() override { ++EndCalled; } std::unique_ptr<ASTConsumer> newASTConsumer() { - return llvm::make_unique<FindTopLevelDeclConsumer>(&Matched); + return std::make_unique<FindTopLevelDeclConsumer>(&Matched); } unsigned BeginCalled; unsigned EndCalled; @@ -249,7 +249,7 @@ struct SkipBodyAction : public clang::ASTFrontendAction { std::unique_ptr<ASTConsumer> CreateASTConsumer(CompilerInstance &Compiler, StringRef) override { Compiler.getFrontendOpts().SkipFunctionBodies = true; - return llvm::make_unique<SkipBodyConsumer>(); + return std::make_unique<SkipBodyConsumer>(); } }; @@ -340,7 +340,7 @@ struct CheckColoredDiagnosticsAction : public clang::ASTFrontendAction { Compiler.getDiagnostics().getCustomDiagID( DiagnosticsEngine::Fatal, "getDiagnosticOpts().ShowColors != ShouldShowColor")); - return llvm::make_unique<ASTConsumer>(); + return std::make_unique<ASTConsumer>(); } private: @@ -651,7 +651,7 @@ TEST(runToolOnCode, TestResetDiagnostics) { return true; } }; - return llvm::make_unique<Consumer>(); + return std::make_unique<Consumer>(); } }; |