From d90e70819543a7a3aa099bb6cf1703551edfe306 Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Sat, 7 Feb 2009 22:36:41 +0000 Subject: [PATCH] Use BugReport::getDescription() for the compiler warning text. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64038 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Analysis/BugReporter.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Analysis/BugReporter.cpp b/lib/Analysis/BugReporter.cpp index c42218e506..7a49112183 100644 --- a/lib/Analysis/BugReporter.cpp +++ b/lib/Analysis/BugReporter.cpp @@ -813,8 +813,8 @@ void BugReporter::FlushReport(BugReportEquivClass& EQ) { R.getRanges(*this, Beg, End); Diagnostic& Diag = getDiagnostic(); FullSourceLoc L(R.getLocation(), getSourceManager()); - const std::string &msg = PD ? R.getBugType().getName() : R.getDescription(); - unsigned ErrorDiag = Diag.getCustomDiagID(Diagnostic::Warning, msg.c_str()); + unsigned ErrorDiag = Diag.getCustomDiagID(Diagnostic::Warning, + R.getDescription().c_str()); switch (End-Beg) { default: assert(0 && "Don't handle this many ranges yet!"); -- 2.40.0