[cfe-commits] r60116 - /cfe/trunk/include/clang/Basic/Diagnostic.h

Argiris Kirtzidis akyrtzi at gmail.com
Wed Nov 26 12:39:45 PST 2008


Author: akirtzidis
Date: Wed Nov 26 14:39:45 2008
New Revision: 60116

URL: http://llvm.org/viewvc/llvm-project?rev=60116&view=rev
Log:
Add an overload for operator<<(const DiagnosticBuilder &DB,bool I).
Fixes building error on MSVC where passing bool couldn't resolve to one of the overloads.

Modified:
    cfe/trunk/include/clang/Basic/Diagnostic.h

Modified: cfe/trunk/include/clang/Basic/Diagnostic.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/Diagnostic.h?rev=60116&r1=60115&r2=60116&view=diff

==============================================================================
--- cfe/trunk/include/clang/Basic/Diagnostic.h (original)
+++ cfe/trunk/include/clang/Basic/Diagnostic.h Wed Nov 26 14:39:45 2008
@@ -357,6 +357,11 @@
   return DB;
 }
 
+inline const DiagnosticBuilder &operator<<(const DiagnosticBuilder &DB,bool I) {
+  DB.AddTaggedVal(I, Diagnostic::ak_sint);
+  return DB;
+}
+
 inline const DiagnosticBuilder &operator<<(const DiagnosticBuilder &DB,
                                            unsigned I) {
   DB.AddTaggedVal(I, Diagnostic::ak_uint);





More information about the cfe-commits mailing list