From: Artem Dergachev Date: Tue, 20 Aug 2019 02:15:47 +0000 (+0000) Subject: [analyzer] NFC: Drop support for extra text attached to bug reports. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=37d1817c7e58ccd7c13e873a390ad16aaecd983a;p=clang [analyzer] NFC: Drop support for extra text attached to bug reports. It was introduced in 2011 but never used since then. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@369319 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h b/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h index 95aab663e2..046847b7db 100644 --- a/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h +++ b/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h @@ -88,7 +88,6 @@ public: using VisitorList = SmallVector, 8>; using visitor_iterator = VisitorList::iterator; using visitor_range = llvm::iterator_range; - using ExtraTextList = SmallVector; using NoteList = SmallVector, 4>; protected: @@ -106,7 +105,6 @@ protected: const ExplodedNode *ErrorNode = nullptr; SmallVector Ranges; const SourceRange ErrorNodeRange; - ExtraTextList ExtraText; NoteList Notes; /// A (stack of) a set of symbols that are registered with this @@ -288,17 +286,6 @@ public: return Notes; } - /// This allows for addition of meta data to the diagnostic. - /// - /// Currently, only the HTMLDiagnosticClient knows how to display it. - void addExtraText(StringRef S) { - ExtraText.push_back(S); - } - - virtual const ExtraTextList &getExtraText() { - return ExtraText; - } - /// Return the "definitive" location of the reported bug. /// /// While a bug can span an entire path, usually there is a specific diff --git a/lib/StaticAnalyzer/Core/BugReporter.cpp b/lib/StaticAnalyzer/Core/BugReporter.cpp index 37a3ddecf7..847174af60 100644 --- a/lib/StaticAnalyzer/Core/BugReporter.cpp +++ b/lib/StaticAnalyzer/Core/BugReporter.cpp @@ -2878,11 +2878,6 @@ void BugReporter::FlushReport(BugReportEquivClass& EQ) { Pieces.push_front(*I); } - // Get the meta data. - const BugReport::ExtraTextList &Meta = report->getExtraText(); - for (const auto &i : Meta) - PD->addMeta(i); - updateExecutedLinesWithDiagnosticPieces(*PD); Consumer->HandlePathDiagnostic(std::move(PD)); }