summaryrefslogtreecommitdiffstats
path: root/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2012-08-03 23:31:15 +0000
committerJordan Rose <jordan_rose@apple.com>2012-08-03 23:31:15 +0000
commit17a8757a46ede9028024211d293bb473ae3de5ff (patch)
treef14a0647de38d870bda7b3bf4eaccefda15e0d64 /clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
parent874886cd66261b7e5039a975769503f53cdd42db (diff)
downloadbcm5719-llvm-17a8757a46ede9028024211d293bb473ae3de5ff.tar.gz
bcm5719-llvm-17a8757a46ede9028024211d293bb473ae3de5ff.zip
[analyzer] Update initializer assertion for delegating constructors.
Like base constructors, delegating constructors require no further processing in the CFGInitializer node. Also, add PrettyStackTraceLoc to the initializer and destructor logic so we can get better stack traces in the future. llvm-svn: 161283
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp')
-rw-r--r--clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp b/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
index d0a0e32f74d..44a860f689d 100644
--- a/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
+++ b/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
@@ -17,6 +17,7 @@
#include "clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h"
#include "clang/AST/DeclCXX.h"
#include "clang/AST/StmtCXX.h"
+#include "clang/Basic/PrettyStackTrace.h"
using namespace clang;
using namespace ento;
@@ -172,6 +173,10 @@ void ExprEngine::VisitCXXDestructor(QualType ObjectType,
CallEventRef<CXXDestructorCall> Call =
CEMgr.getCXXDestructorCall(DtorDecl, S, Dest, State, LCtx);
+ PrettyStackTraceLoc CrashInfo(getContext().getSourceManager(),
+ Call->getSourceRange().getBegin(),
+ "Error evaluating destructor");
+
ExplodedNodeSet DstPreCall;
getCheckerManager().runCheckersForPreCall(DstPreCall, Pred,
*Call, *this);
OpenPOWER on IntegriCloud