aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Analysis/PathSensitive/AnalysisContext.h
diff options
context:
space:
mode:
authorRoman Divacky <rdivacky@FreeBSD.org>2009-11-04 15:04:32 +0000
committerRoman Divacky <rdivacky@FreeBSD.org>2009-11-04 15:04:32 +0000
commit51fb8b013e7734b795139f49d3b1f77c539be20a (patch)
tree59e0e47a9831dcf0e21e547927c8ebb7e113bfd1 /include/clang/Analysis/PathSensitive/AnalysisContext.h
parent73490b890977362d28dd6326843a1ecae413921d (diff)
downloadsrc-51fb8b013e7734b795139f49d3b1f77c539be20a.tar.gz
src-51fb8b013e7734b795139f49d3b1f77c539be20a.zip
Update clang to r86025.vendor/clang/clang-r86025
Notes
Notes: svn path=/vendor/clang/dist/; revision=198893 svn path=/vendor/clang/clang-r86025/; revision=198895; tag=vendor/clang/clang-r86025
Diffstat (limited to 'include/clang/Analysis/PathSensitive/AnalysisContext.h')
-rw-r--r--include/clang/Analysis/PathSensitive/AnalysisContext.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/include/clang/Analysis/PathSensitive/AnalysisContext.h b/include/clang/Analysis/PathSensitive/AnalysisContext.h
index 8e02ccf38209..66e850a91444 100644
--- a/include/clang/Analysis/PathSensitive/AnalysisContext.h
+++ b/include/clang/Analysis/PathSensitive/AnalysisContext.h
@@ -80,6 +80,8 @@ protected:
: Kind(k), Ctx(ctx), Parent(parent) {}
public:
+ virtual ~LocationContext() {}
+
ContextKind getKind() const { return Kind; }
AnalysisContext *getAnalysisContext() const { return Ctx; }
@@ -102,7 +104,7 @@ public:
return Ctx->getSelfDecl();
}
- void Profile(llvm::FoldingSetNodeID &ID) {
+ virtual void Profile(llvm::FoldingSetNodeID &ID) {
Profile(ID, Kind, Ctx, Parent);
}
@@ -119,10 +121,13 @@ public:
StackFrameContext(AnalysisContext *ctx, const LocationContext *parent,
const Stmt *s)
: LocationContext(StackFrame, ctx, parent), CallSite(s) {}
+
+ virtual ~StackFrameContext() {}
+
Stmt const *getCallSite() const { return CallSite; }
- void Profile(llvm::FoldingSetNodeID &ID) {
+ virtual void Profile(llvm::FoldingSetNodeID &ID) {
Profile(ID, getAnalysisContext(), getParent(), CallSite);
}
@@ -141,8 +146,10 @@ public:
ScopeContext(AnalysisContext *ctx, const LocationContext *parent,
const Stmt *s)
: LocationContext(Scope, ctx, parent), Enter(s) {}
+
+ virtual ~ScopeContext() {}
- void Profile(llvm::FoldingSetNodeID &ID) {
+ virtual void Profile(llvm::FoldingSetNodeID &ID) {
Profile(ID, getAnalysisContext(), getParent(), Enter);
}