diff options
author | Jordan Rose <jordan_rose@apple.com> | 2012-08-03 23:09:01 +0000 |
---|---|---|
committer | Jordan Rose <jordan_rose@apple.com> | 2012-08-03 23:09:01 +0000 |
commit | cfb4eb293fd8be1d3d247690f65606836431d1c1 (patch) | |
tree | e1241953b9bcb7d48ad8745d9c310a6e2e5625d4 /clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp | |
parent | 3eb3cd45b82855486b79e6a01add7899f07970fb (diff) | |
download | bcm5719-llvm-cfb4eb293fd8be1d3d247690f65606836431d1c1.tar.gz bcm5719-llvm-cfb4eb293fd8be1d3d247690f65606836431d1c1.zip |
[analyzer] When a symbol is null, we should track its constraints.
Because of this, we would previously emit NO path notes when a parameter
is constrained to null (because there are no stores). Now we show where we
made the assumption, which is much more useful.
llvm-svn: 161280
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp index 5094a033623..dcf6a8603ec 100644 --- a/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp @@ -42,8 +42,9 @@ void DivZeroChecker::reportBug(const char *Msg, BugReport *R = new BugReport(*BT, Msg, N); - R->addVisitor(bugreporter::getTrackNullOrUndefValueVisitor(N, - bugreporter::GetDenomExpr(N), R)); + bugreporter::addTrackNullOrUndefValueVisitor(N, + bugreporter::GetDenomExpr(N), + R); C.EmitReport(R); } } |