From 9bea0dc178d273f91452f1c30604205cbfba39bf Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Tue, 28 Apr 2009 04:28:12 +0000 Subject: Extensive diagnostics: Do not add a location context for do...while statements. llvm-svn: 70286 --- clang/lib/Analysis/BugReporter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/lib/Analysis/BugReporter.cpp') diff --git a/clang/lib/Analysis/BugReporter.cpp b/clang/lib/Analysis/BugReporter.cpp index 8db4dfa2473..3c814dbb67b 100644 --- a/clang/lib/Analysis/BugReporter.cpp +++ b/clang/lib/Analysis/BugReporter.cpp @@ -1010,7 +1010,7 @@ static void GenerateExtensivePathDiagnostic(PathDiagnostic& PD, const CFGBlock &Blk = *BE->getSrc(); const Stmt *Term = Blk.getTerminator(); - if (Term) + if (Term && !isa(Term)) EB.addContext(Term); // Are we jumping to the head of a loop? Add a special diagnostic. -- cgit v1.2.3