For HTML diagnostics, output more information about a bug report.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49742 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/HTMLDiagnostics.cpp b/Driver/HTMLDiagnostics.cpp
index 05e4a51..327a77f 100644
--- a/Driver/HTMLDiagnostics.cpp
+++ b/Driver/HTMLDiagnostics.cpp
@@ -124,14 +124,26 @@
   if (DirName == ".")
     DirName = llvm::sys::Path::GetCurrentDirectory().toString();
     
-  // Add the name of the file as an <h1> tag.
-
+  // Add the name of the file as an <h1> tag.  
+  
   {
     std::ostringstream os;
     
-    os << "<h1>" << html::EscapeText(DirName)
-       << "/"    << html::EscapeText(Entry->getName()) << "</h1>\n";
-
+    os << "<h3>Bug Summary</h3>\n<table class=\"simpletable\">\n"
+          "<tr><td class=\"rowname\">File:</td><td>"
+       << html::EscapeText(DirName)
+       << html::EscapeText(Entry->getName())
+       << "</td></tr>\n<tr><td class=\"rowname\">Location:</td><td>"
+          "<a href=\"#EndPath\">line "      
+       << (*D.rbegin()).getLocation().getLogicalLineNumber()
+       << ", column "
+       << (*D.rbegin()).getLocation().getLogicalColumnNumber()
+       << "</a></td></tr>\n"
+          "<tr><td class=\"rowname\">Description:</td><td>"
+       << D.getDescription()
+       << "</td></tr>\n</table>\n"
+          "<h3>Annotated Source Code</h3>\n";
+    
     R.InsertStrBefore(SourceLocation::getFileLoc(FileID, 0), os.str());
   }