diff options
author | Manuel Klimek <klimek@google.com> | 2012-04-20 14:07:01 +0000 |
---|---|---|
committer | Manuel Klimek <klimek@google.com> | 2012-04-20 14:07:01 +0000 |
commit | 21a7a5e8cffe48b823d8930380cb2748193e5cc5 (patch) | |
tree | 9cbe0ed33c911d2c1675fc0f15cb778f72d322f5 /clang/unittests/Tooling/RecursiveASTVisitorTest.cpp | |
parent | e2f9a21db59d32210488952f2a8b72eff06f6306 (diff) | |
download | bcm5719-llvm-21a7a5e8cffe48b823d8930380cb2748193e5cc5.tar.gz bcm5719-llvm-21a7a5e8cffe48b823d8930380cb2748193e5cc5.zip |
No need to put the SourceManager in with the ASTContext, as the ASTContext
already contains the SourceManager.
llvm-svn: 155198
Diffstat (limited to 'clang/unittests/Tooling/RecursiveASTVisitorTest.cpp')
-rw-r--r-- | clang/unittests/Tooling/RecursiveASTVisitorTest.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp b/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp index d749f76a22b..d7dad2738a0 100644 --- a/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp +++ b/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp @@ -38,7 +38,6 @@ public: protected: clang::ASTContext *Context; - clang::SourceManager *SM; private: class FindConsumer : public clang::ASTConsumer { @@ -59,7 +58,6 @@ private: virtual clang::ASTConsumer* CreateASTConsumer( clang::CompilerInstance& compiler, llvm::StringRef dummy) { - Visitor->SM = &compiler.getSourceManager(); Visitor->Context = &compiler.getASTContext(); /// TestConsumer will be deleted by the framework calling us. return new FindConsumer(Visitor); @@ -116,7 +114,7 @@ protected: // If we did not match, record information about partial matches. llvm::raw_string_ostream Stream(PartialMatches); Stream << ", partial match: \"" << Name << "\" at "; - Location.print(Stream, *this->SM); + Location.print(Stream, this->Context->getSourceManager()); } } |