aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/BugReporter.cpp
diff options
context:
space:
mode:
authorSebastian Redl <sebastian.redl@getdesigned.at>2009-04-26 20:35:05 +0000
committerSebastian Redl <sebastian.redl@getdesigned.at>2009-04-26 20:35:05 +0000
commitd3a413d3b8eb39bcee5944bc545d9997c1abe492 (patch)
tree9c84c3e5e12e5fd96b0aee7dd662e61e6d230359 /lib/Analysis/BugReporter.cpp
parent9a901bb63990574ff0bcc12ff851d7a71cff8ddb (diff)
Implement function-try-blocks. However, there's a very subtle bug that I can't track down.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70155 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/BugReporter.cpp')
-rw-r--r--lib/Analysis/BugReporter.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Analysis/BugReporter.cpp b/lib/Analysis/BugReporter.cpp
index 348ab3d09a..397d28b6e2 100644
--- a/lib/Analysis/BugReporter.cpp
+++ b/lib/Analysis/BugReporter.cpp
@@ -189,7 +189,7 @@ PathDiagnosticBuilder::ExecutionContinues(const ExplodedNode<GRState>* N) {
if (Stmt *S = GetNextStmt(N))
return PathDiagnosticLocation(S, SMgr);
- return FullSourceLoc(CodeDecl.getBody(getContext())->getRBracLoc(), SMgr);
+ return FullSourceLoc(CodeDecl.getBodyRBrace(getContext()), SMgr);
}
PathDiagnosticLocation
@@ -825,7 +825,9 @@ public:
// Finally, add an initial edge from the start location of the first
// statement (if it doesn't already exist).
- if (const CompoundStmt *CS = PDB.getCodeDecl().getBody(PDB.getContext()))
+ // FIXME: Should handle CXXTryStmt if analyser starts supporting C++.
+ if (const CompoundStmt *CS =
+ PDB.getCodeDecl().getCompoundBody(PDB.getContext()))
if (!CS->body_empty()) {
SourceLocation Loc = (*CS->body_begin())->getLocStart();
rawAddEdge(PathDiagnosticLocation(Loc, PDB.getSourceManager()));