diff options
author | Ted Kremenek <kremenek@apple.com> | 2012-01-07 00:00:59 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2012-01-07 00:00:59 +0000 |
commit | aee86cee357a5839c5d01633187590c4a5e4ce71 (patch) | |
tree | 8f3c612490d9a93d283878c68f14d052593ff49c /clang/lib/StaticAnalyzer/Core/CoreEngine.cpp | |
parent | 73a3fab480de3804b755d50e427f5d2cda0b6866 (diff) | |
download | bcm5719-llvm-aee86cee357a5839c5d01633187590c4a5e4ce71.tar.gz bcm5719-llvm-aee86cee357a5839c5d01633187590c4a5e4ce71.zip |
[analyzer] Remove CallExitNodeBuilder, and have ExprEngine::processCallExit() do the work manually. This is a nice simplification.
Along the way, fix Exprengine::processCallExit() to also perform the postStmt callback for checkers for CallExprs.
llvm-svn: 147697
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/CoreEngine.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Core/CoreEngine.cpp | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp b/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp index bf4bf2db886..c505c44a971 100644 --- a/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp +++ b/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp @@ -254,8 +254,7 @@ void CoreEngine::HandleCallEnter(const CallEnter &L, const CFGBlock *Block, } void CoreEngine::HandleCallExit(const CallExit &L, ExplodedNode *Pred) { - CallExitNodeBuilder Builder(*this, Pred); - SubEng.processCallExit(Builder); + SubEng.processCallExit(Pred); } void CoreEngine::HandleBlockEdge(const BlockEdge &L, ExplodedNode *Pred) { @@ -707,18 +706,3 @@ void CallEnterNodeBuilder::generateNode(const ProgramState *state) { if (isNew) Eng.WList->enqueue(Node); } - -void CallExitNodeBuilder::generateNode(const ProgramState *state) { - // Get the callee's location context. - const StackFrameContext *LocCtx - = cast<StackFrameContext>(Pred->getLocationContext()); - // When exiting an implicit automatic obj dtor call, the callsite is the Stmt - // that triggers the dtor. - PostStmt Loc(LocCtx->getCallSite(), LocCtx->getParent()); - bool isNew; - ExplodedNode *Node = Eng.G->getNode(Loc, state, false, &isNew); - Node->addPredecessor(const_cast<ExplodedNode*>(Pred), *Eng.G); - if (isNew) - Eng.WList->enqueue(Node, LocCtx->getCallSiteBlock(), - LocCtx->getIndex() + 1); -} |