[cfe-commits] r91566 - /cfe/trunk/test/SemaCXX/enum.cpp
Eli Friedman
eli.friedman at gmail.com
Wed Dec 16 12:47:15 PST 2009
Author: efriedma
Date: Wed Dec 16 14:47:15 2009
New Revision: 91566
URL: http://llvm.org/viewvc/llvm-project?rev=91566&view=rev
Log:
Fix test.
Modified:
cfe/trunk/test/SemaCXX/enum.cpp
Modified: cfe/trunk/test/SemaCXX/enum.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCXX/enum.cpp?rev=91566&r1=91565&r2=91566&view=diff
==============================================================================
--- cfe/trunk/test/SemaCXX/enum.cpp (original)
+++ cfe/trunk/test/SemaCXX/enum.cpp Wed Dec 16 14:47:15 2009
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -pedantic -std=c++98 -verify %s
+// RUN: %clang_cc1 -fsyntax-only -pedantic -std=c++98 -verify -triple x86_64-apple-darwin %s
enum E {
Val1,
@@ -50,18 +50,9 @@
enum enum2 { v2 = __INT_MAX__ * 2U };
int test2[is_same<__typeof(+v2), unsigned int>::value];
- // This kindof assumes that 'int' is smaller than 'long long'.
-#if defined(__LP64__)
enum enum3 { v3 = __LONG_MAX__ };
int test3[is_same<__typeof(+v3), long>::value];
enum enum4 { v4 = __LONG_MAX__ * 2UL };
int test4[is_same<__typeof(+v4), unsigned long>::value];
-#else
- enum enum3 { v3 = __LONG_LONG_MAX__ };
- int test3[is_same<__typeof(+v3), long long>::value]; // expected-warning {{'long long' is an extension}}
-
- enum enum4 { v4 = __LONG_LONG_MAX__ * 2ULL }; // expected-warning {{'long long' is an extension}}
- int test4[is_same<__typeof(+v4), unsigned long long>::value]; // expected-warning {{'long long' is an extension}}
-#endif
}
More information about the cfe-commits
mailing list