diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2010-07-17 13:51:58 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2010-07-17 13:51:58 +0000 |
commit | ee30965ce96e0a7b04b1aa16df60e9ba8b0a33c9 (patch) | |
tree | 1e3565168daf72c00eb5d39e2c2897a2ada1cca5 /include/clang/Analysis/AnalysisContext.h | |
parent | 5a9ac23182abfec4e04bf9d7d0c23ededf9a87c6 (diff) |
Revert r108617, it broke the build.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108621 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Analysis/AnalysisContext.h')
-rw-r--r-- | include/clang/Analysis/AnalysisContext.h | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/include/clang/Analysis/AnalysisContext.h b/include/clang/Analysis/AnalysisContext.h index 584173a33f..9ebd93b75b 100644 --- a/include/clang/Analysis/AnalysisContext.h +++ b/include/clang/Analysis/AnalysisContext.h @@ -34,16 +34,11 @@ class ImplicitParamDecl; class LocationContextManager; class StackFrameContext; -namespace idx { class TranslationUnit; } - /// AnalysisContext contains the context data for the function or method under /// analysis. class AnalysisContext { const Decl *D; - // TranslationUnit is NULL if we don't have multiple translation units. - const idx::TranslationUnit *TU; - // AnalysisContext owns the following data. CFG *cfg; bool builtCFG; @@ -53,18 +48,14 @@ class AnalysisContext { llvm::BumpPtrAllocator A; bool AddEHEdges; public: - AnalysisContext(const Decl *d, const idx::TranslationUnit *tu, - bool addehedges = false) - : D(d), TU(tu), cfg(0), builtCFG(false), liveness(0), PM(0), + AnalysisContext(const Decl *d, bool addehedges = false) + : D(d), cfg(0), builtCFG(false), liveness(0), PM(0), ReferencedBlockVars(0), AddEHEdges(addehedges) {} ~AnalysisContext(); ASTContext &getASTContext() { return D->getASTContext(); } - const Decl *getDecl() const { return D; } - - const idx::TranslationUnit *getTranslationUnit() const { return TU; } - + const Decl *getDecl() { return D; } /// getAddEHEdges - Return true iff we are adding exceptional edges from /// callExprs. If this is false, then try/catch statements and blocks /// reachable from them can appear to be dead in the CFG, analysis passes must @@ -91,7 +82,7 @@ class AnalysisContextManager { public: ~AnalysisContextManager(); - AnalysisContext *getContext(const Decl *D,const idx::TranslationUnit *TU = 0); + AnalysisContext *getContext(const Decl *D); // Discard all previously created AnalysisContexts. void clear(); @@ -118,10 +109,6 @@ public: AnalysisContext *getAnalysisContext() const { return Ctx; } - const idx::TranslationUnit *getTranslationUnit() const { - return Ctx->getTranslationUnit(); - } - const LocationContext *getParent() const { return Parent; } bool isParentOf(const LocationContext *LC) const; |