aboutsummaryrefslogtreecommitdiff
path: root/lib/Driver/HTMLDiagnostics.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-09-20 04:23:38 +0000
committerTed Kremenek <kremenek@apple.com>2008-09-20 04:23:38 +0000
commit8c036c7f77d69f96df49219ed0bdbade200d52eb (patch)
tree42a60273cdaf9151779429a5e169ecd21a06afd5 /lib/Driver/HTMLDiagnostics.cpp
parent82bae3f6bf7bc4733d9c87659b266e23ad55f420 (diff)
Add "category" to BugTypes, allowing bugs to be grouped.
Changed casing of many bug names. The convention will be to have bug names (mostly) lower cased, and categories use some capitalization. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56385 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/HTMLDiagnostics.cpp')
-rw-r--r--lib/Driver/HTMLDiagnostics.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Driver/HTMLDiagnostics.cpp b/lib/Driver/HTMLDiagnostics.cpp
index 5025e87e59..22d3da9320 100644
--- a/lib/Driver/HTMLDiagnostics.cpp
+++ b/lib/Driver/HTMLDiagnostics.cpp
@@ -259,6 +259,15 @@ void HTMLDiagnostics::ReportDiag(const PathDiagnostic& D) {
R.InsertStrBefore(SourceLocation::getFileLoc(FileID, 0), os.str());
}
+ const std::string& BugCategory = D.getCategory();
+
+ if (!BugCategory.empty()) {
+ std::string s;
+ llvm::raw_string_ostream os(s);
+ os << "\n<!-- BUGCATEGORY " << BugCategory << " -->\n";
+ R.InsertStrBefore(SourceLocation::getFileLoc(FileID, 0), os.str());
+ }
+
{
std::string s;
llvm::raw_string_ostream os(s);