[cfe-commits] r54882 - in /cfe/trunk: include/clang/AST/Type.h test/SemaCXX/wchar_t.cpp

Argiris Kirtzidis akyrtzi at gmail.com
Sun Aug 17 06:24:02 PDT 2008


Author: akirtzidis
Date: Sun Aug 17 08:24:01 2008
New Revision: 54882

URL: http://llvm.org/viewvc/llvm-project?rev=54882&view=rev
Log:
Type::isIntegerType() returns true for types between Bool and LongLong.
Put WChar between them to make it integer type.

Modified:
    cfe/trunk/include/clang/AST/Type.h
    cfe/trunk/test/SemaCXX/wchar_t.cpp

Modified: cfe/trunk/include/clang/AST/Type.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Type.h?rev=54882&r1=54881&r2=54882&view=diff

==============================================================================
--- cfe/trunk/include/clang/AST/Type.h (original)
+++ cfe/trunk/include/clang/AST/Type.h Sun Aug 17 08:24:01 2008
@@ -471,14 +471,13 @@
     
     Char_S,   // This is 'char' for targets where char is signed.
     SChar,    // This is explicitly qualified signed char.
+    WChar,    // This is 'wchar_t' for C++.
     Short,
     Int,
     Long,
     LongLong,
     
-    Float, Double, LongDouble,
-
-    WChar     // This is 'wchar_t' for C++.
+    Float, Double, LongDouble
   };
 private:
   Kind TypeKind;

Modified: cfe/trunk/test/SemaCXX/wchar_t.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCXX/wchar_t.cpp?rev=54882&r1=54881&r2=54882&view=diff

==============================================================================
--- cfe/trunk/test/SemaCXX/wchar_t.cpp (original)
+++ cfe/trunk/test/SemaCXX/wchar_t.cpp Sun Aug 17 08:24:01 2008
@@ -5,4 +5,5 @@
   wchar_t x;
   unsigned wchar_t y; // expected-warning {{'wchar_t' cannot be signed or unsigned}}
   signed wchar_t z; // expected-warning {{'wchar_t' cannot be signed or unsigned}}
+  ++x;
 }





More information about the cfe-commits mailing list