diff options
author | Jordan Rose <jordan_rose@apple.com> | 2012-07-10 22:07:42 +0000 |
---|---|---|
committer | Jordan Rose <jordan_rose@apple.com> | 2012-07-10 22:07:42 +0000 |
commit | 28038f33aa2db4833881fea757a1f0daf85ac02b (patch) | |
tree | c2814066ca3c1d5e9a807ee488a5f9d27ce0e9a8 /lib/StaticAnalyzer/Core/CheckerManager.cpp | |
parent | 13106117060c90d6f84bd2ed7a5c03e0502ff419 (diff) |
[analyzer] Add new PreImplicitCall and PostImplicitCall ProgramPoints.
These are currently unused, but are intended to be used in lieu of PreStmt
and PostStmt when the call is implicit (e.g. an automatic object destructor).
This also modifies the Data1 field of ProgramPoints to allow storing any
pointer-sized value, as opposed to only aligned pointers. This is necessary
to store SourceLocations.
There is currently no BugReporter support for these; they should be skipped
over in any diagnostic output.
This commit also tags checkers that currently rely on function calls only
occurring at StmtPoints.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@160019 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core/CheckerManager.cpp')
-rw-r--r-- | lib/StaticAnalyzer/Core/CheckerManager.cpp | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/lib/StaticAnalyzer/Core/CheckerManager.cpp b/lib/StaticAnalyzer/Core/CheckerManager.cpp index 39a3621826..d0d212130a 100644 --- a/lib/StaticAnalyzer/Core/CheckerManager.cpp +++ b/lib/StaticAnalyzer/Core/CheckerManager.cpp @@ -237,15 +237,7 @@ namespace { void runChecker(CheckerManager::CheckCallFunc checkFn, NodeBuilder &Bldr, ExplodedNode *Pred) { - // FIXME: This will be wrong as soon as we handle any calls without - // associated statements. - ProgramPoint::Kind K = IsPreVisit ? ProgramPoint::PreStmtKind - : ProgramPoint::PostStmtKind; - assert(Call.getOriginExpr() && "Calls without stmts not yet handled"); - const ProgramPoint &L = - ProgramPoint::getProgramPoint(Call.getOriginExpr(), - K, Pred->getLocationContext(), - checkFn.Checker); + const ProgramPoint &L = Call.getProgramPoint(IsPreVisit, checkFn.Checker); CheckerContext C(Bldr, Eng, Pred, L); checkFn(Call, C); |