From dd5dcddd4129abf56d69a0d5b380cc7c31ef07ee Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Fri, 29 Jun 2018 20:41:23 +0000 Subject: [PATCH] Specify an explicit underlying type for this enum to fix Windows buildbots. On Windows targets, enums always get an underlying type of 'int', even if they have wider enumerators. (This is non-conforming, but it's effectively part of the target ABI.) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@336013 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CXX/conv/conv.prom/p5.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/CXX/conv/conv.prom/p5.cpp b/test/CXX/conv/conv.prom/p5.cpp index baf51374c8..0c72ebce4a 100644 --- a/test/CXX/conv/conv.prom/p5.cpp +++ b/test/CXX/conv/conv.prom/p5.cpp @@ -8,7 +8,7 @@ static_assert(sizeof(+X().e) == sizeof(int), ""); static_assert(sizeof(X().e + 1) == sizeof(int), ""); static_assert(sizeof(true ? X().e : 0) == sizeof(int), ""); -enum E { a = __LONG_LONG_MAX__ }; +enum E : long long { a = __LONG_LONG_MAX__ }; static_assert(sizeof(E{}) == sizeof(long long), ""); // If the bit-field has an enumerated type, it is treated as any other value of -- 2.50.1