summaryrefslogtreecommitdiffstats
path: root/clang/Analysis/GRExprEngine.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-02-25 21:16:03 +0000
committerTed Kremenek <kremenek@apple.com>2008-02-25 21:16:03 +0000
commit3a6fd9c177a1b217655f4b7b222fde877e0e630c (patch)
tree7264a2b1e93505e2f9f3e2ba3dcc2ced901ca0e5 /clang/Analysis/GRExprEngine.cpp
parent1f372edd97c15455c113ffdcc786b52e95c41b5f (diff)
downloadbcm5719-llvm-3a6fd9c177a1b217655f4b7b222fde877e0e630c.tar.gz
bcm5719-llvm-3a6fd9c177a1b217655f4b7b222fde877e0e630c.zip
Better handling of calls to functions via function pointers.
llvm-svn: 47562
Diffstat (limited to 'clang/Analysis/GRExprEngine.cpp')
-rw-r--r--clang/Analysis/GRExprEngine.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/clang/Analysis/GRExprEngine.cpp b/clang/Analysis/GRExprEngine.cpp
index dedeb7b1b70..4e6d1a3f6b3 100644
--- a/clang/Analysis/GRExprEngine.cpp
+++ b/clang/Analysis/GRExprEngine.cpp
@@ -429,14 +429,16 @@ void GRExprEngine::VisitCall(CallExpr* CE, NodeTy* Pred,
// If we reach here we have processed all of the arguments. Evaluate
// the callee expression.
- NodeSet DstTmp;
- Visit(CE->getCallee(), Pred, DstTmp);
+ NodeSet DstTmp;
+ Expr* Callee = CE->getCallee()->IgnoreParenCasts();
+
+ VisitLVal(Callee, Pred, DstTmp);
// Finally, evaluate the function call.
for (NodeSet::iterator DI = DstTmp.begin(), DE = DstTmp.end(); DI!=DE; ++DI) {
StateTy St = (*DI)->getState();
- RVal L = GetLVal(St, CE->getCallee());
+ RVal L = GetLVal(St, Callee);
// Check for uninitialized control-flow.
OpenPOWER on IntegriCloud