[llvm-commits] [llvm] r132046 - /llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp
Argyrios Kyrtzidis
akyrtzi at gmail.com
Tue May 24 22:04:22 PDT 2011
Author: akirtzidis
Date: Wed May 25 00:04:22 2011
New Revision: 132046
URL: http://llvm.org/viewvc/llvm-project?rev=132046&view=rev
Log:
[tablegen] A couple of changes to ClangDiagnosticEmmitter.
-Emit an empty warning option as string ("") instead of 0.
-For diagnostic names also emit the size of the string.
Modified:
llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp
Modified: llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp?rev=132046&r1=132045&r2=132046&view=diff
==============================================================================
--- llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp (original)
+++ llvm/trunk/utils/TableGen/ClangDiagnosticsEmitter.cpp Wed May 25 00:04:22 2011
@@ -162,7 +162,7 @@
OS << ", \"";
OS.write_escaped(DI->getDef()->getValueAsString("GroupName")) << '"';
} else {
- OS << ", 0";
+ OS << ", \"\"";
}
// SFINAE bit
@@ -275,7 +275,9 @@
for (std::map<std::string, GroupInfo>::iterator
I = DiagsInGroup.begin(), E = DiagsInGroup.end(); I != E; ++I) {
// Group option string.
- OS << " { \"";
+ OS << " { ";
+ OS << I->first.size() << ", ";
+ OS << "\"";
OS.write_escaped(I->first) << "\","
<< std::string(MaxLen-I->first.size()+1, ' ');
More information about the llvm-commits
mailing list