r330690 - [AST] Another attempt at fixing the ARM bots.

Benjamin Kramer via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 24 01:18:33 PDT 2018


Author: d0k
Date: Tue Apr 24 01:18:32 2018
New Revision: 330690

URL: http://llvm.org/viewvc/llvm-project?rev=330690&view=rev
Log:
[AST] Another attempt at fixing the ARM bots.

Modified:
    cfe/trunk/test/SemaCXX/constexpr-string.cpp

Modified: cfe/trunk/test/SemaCXX/constexpr-string.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCXX/constexpr-string.cpp?rev=330690&r1=330689&r2=330690&view=diff
==============================================================================
--- cfe/trunk/test/SemaCXX/constexpr-string.cpp (original)
+++ cfe/trunk/test/SemaCXX/constexpr-string.cpp Tue Apr 24 01:18:32 2018
@@ -107,7 +107,7 @@ namespace WcscmpEtc {
   static_assert(__builtin_wcscmp(L"abab", L"abab\0banana") == 0);
   static_assert(__builtin_wcscmp(L"abab\0banana", L"abab\0canada") == 0);
 #if __WCHAR_WIDTH__ == 32
-  static_assert(__builtin_wcscmp(L"a\x83838383", L"a") == wchar_t(-1U) >> 31);
+  static_assert(__builtin_wcscmp(L"a\x83838383", L"a") == (wchar_t)-1U >> 31);
 #endif
   static_assert(__builtin_wcscmp(0, L"abab") == 0); // expected-error {{not an integral constant}} expected-note {{dereferenced null}}
   static_assert(__builtin_wcscmp(L"abab", 0) == 0); // expected-error {{not an integral constant}} expected-note {{dereferenced null}}
@@ -125,7 +125,7 @@ namespace WcscmpEtc {
   static_assert(__builtin_wcsncmp(L"abab\0banana", L"abab\0canada", 100) == 0);
 #if __WCHAR_WIDTH__ == 32
   static_assert(__builtin_wcsncmp(L"a\x83838383", L"aa", 2) ==
-                wchar_t(-1U) >> 31);
+                (wchar_t)-1U >> 31);
 #endif
 
   static_assert(__builtin_wcsncmp(kFoobar, kFoobazfoobar, 6) == -1);
@@ -138,7 +138,7 @@ namespace WcscmpEtc {
   static_assert(__builtin_wmemcmp(0, 0, 0) == 0);
 #if __WCHAR_WIDTH__ == 32
   static_assert(__builtin_wmemcmp(L"a\x83838383", L"aa", 2) ==
-                wchar_t(-1U) >> 31);
+                (wchar_t)-1U >> 31);
 #endif
   static_assert(__builtin_wmemcmp(L"abab\0banana", L"abab\0banana", 100) == 0); // expected-error {{not an integral constant}} expected-note {{dereferenced one-past-the-end}}
   static_assert(__builtin_wmemcmp(L"abab\0banana", L"abab\0canada", 100) == -1); // FIXME: Should we reject this?




More information about the cfe-commits mailing list