summaryrefslogtreecommitdiffstats
path: root/clang/docs/LibASTMatchersTutorial.rst
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2014-05-01 20:04:39 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2014-05-01 20:04:39 +0000
commit06900a0ffbf847028b603fb00f55da330db7c92e (patch)
treec4a340b97d7c43a827510127071312f20b4c27f4 /clang/docs/LibASTMatchersTutorial.rst
parent6f6875835817ee61bdd1eb0bff0603304b28f02b (diff)
downloadbcm5719-llvm-06900a0ffbf847028b603fb00f55da330db7c92e.tar.gz
bcm5719-llvm-06900a0ffbf847028b603fb00f55da330db7c92e.zip
Update documentation to match recent API change. newFrontendActionFactory now returns a unique_ptr.
llvm-svn: 207789
Diffstat (limited to 'clang/docs/LibASTMatchersTutorial.rst')
-rw-r--r--clang/docs/LibASTMatchersTutorial.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/docs/LibASTMatchersTutorial.rst b/clang/docs/LibASTMatchersTutorial.rst
index 13749fbc41f..1e88ec203c9 100644
--- a/clang/docs/LibASTMatchersTutorial.rst
+++ b/clang/docs/LibASTMatchersTutorial.rst
@@ -153,7 +153,7 @@ documentation <LibTooling.html>`_.
CommonOptionsParser OptionsParser(argc, argv, MyToolCategory);
ClangTool Tool(OptionsParser.getCompilations(),
OptionsParser.getSourcePathList());
- return Tool.run(newFrontendActionFactory<clang::SyntaxOnlyAction>());
+ return Tool.run(newFrontendActionFactory<clang::SyntaxOnlyAction>().get());
}
And that's it! You can compile our new tool by running ninja from the
@@ -299,7 +299,7 @@ And change ``main()`` to:
MatchFinder Finder;
Finder.addMatcher(LoopMatcher, &Printer);
- return Tool.run(newFrontendActionFactory(&Finder));
+ return Tool.run(newFrontendActionFactory(&Finder).get());
}
Now, you should be able to recompile and run the code to discover for
OpenPOWER on IntegriCloud