From 774dfbb046c5087a3b82790833d0604bf4c3be6c Mon Sep 17 00:00:00 2001 From: Argyrios Kyrtzidis Date: Fri, 3 Dec 2010 02:03:26 +0000 Subject: [PATCH] Also show notes about the taken path in TextPathDiagnostics. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120783 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Checker/TextPathDiagnostics.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/lib/Checker/TextPathDiagnostics.cpp b/lib/Checker/TextPathDiagnostics.cpp index 83ff7a4409..0ed03e426d 100644 --- a/lib/Checker/TextPathDiagnostics.cpp +++ b/lib/Checker/TextPathDiagnostics.cpp @@ -38,7 +38,7 @@ public: return "TextPathDiagnostics"; } - PathGenerationScheme getGenerationScheme() const { return Extensive; } + PathGenerationScheme getGenerationScheme() const { return Minimal; } bool supportsLogicalOpControlFlow() const { return true; } bool supportsAllBlockEdges() const { return true; } virtual bool useVerboseDescription() const { return true; } @@ -62,11 +62,8 @@ void TextPathDiagnostics::HandlePathDiagnostic(const PathDiagnostic* D) { } for (PathDiagnostic::const_iterator I=D->begin(), E=D->end(); I != E; ++I) { - if (isa(*I)) { - PathDiagnosticEventPiece &event = cast(*I); - unsigned diagID = Diag.getDiagnosticIDs()->getCustomDiagID( - DiagnosticIDs::Note, event.getString()); - Diag.Report(event.getLocation().asLocation(), diagID); - } + unsigned diagID = Diag.getDiagnosticIDs()->getCustomDiagID( + DiagnosticIDs::Note, I->getString()); + Diag.Report(I->getLocation().asLocation(), diagID); } } -- 2.40.0