[libcxx-commits] [PATCH] D104748: [SystemZ][z/OS][libcxx]: fix libcxx test cases failed on ebcdic mode on z/OS
Muiez Ahmed via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Jun 28 11:05:23 PDT 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rG4f5ebfdcd6c9: [SystemZ][z/OS][libcxx]: fix libcxx test cases failed on ebcdic mode on z/OS (authored by NancyWang2222, committed by muiez).
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104748/new/
https://reviews.llvm.org/D104748
Files:
libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.char/lt.pass.cpp
libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/lt.pass.cpp
Index: libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/lt.pass.cpp
===================================================================
--- libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/lt.pass.cpp
+++ libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/lt.pass.cpp
@@ -19,8 +19,18 @@
int main(int, char**)
{
- assert(!std::char_traits<wchar_t>::lt(L'a', L'a'));
- assert( std::char_traits<wchar_t>::lt(L'A', L'a'));
+ assert(std::char_traits<wchar_t>::lt(L'\0', L'A') == (L'\0' < L'A'));
+ assert(std::char_traits<wchar_t>::lt(L'A', L'\0') == (L'A' < L'\0'));
+
+ assert(std::char_traits<wchar_t>::lt(L'a', L'a') == (L'a' < L'a'));
+ assert(std::char_traits<wchar_t>::lt(L'A', L'a') == (L'A' < L'a'));
+ assert(std::char_traits<wchar_t>::lt(L'a', L'A') == (L'a' < L'A'));
+
+ assert(std::char_traits<wchar_t>::lt(L'a', L'z') == (L'a' < L'z'));
+ assert(std::char_traits<wchar_t>::lt(L'A', L'Z') == (L'A' < L'Z'));
+
+ assert(std::char_traits<wchar_t>::lt(L' ', L'A') == (L' ' < L'A'));
+ assert(std::char_traits<wchar_t>::lt(L'A', L'~') == (L'A' < L'~'));
return 0;
}
Index: libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.char/lt.pass.cpp
===================================================================
--- libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.char/lt.pass.cpp
+++ libcxx/test/std/strings/char.traits/char.traits.specializations/char.traits.specializations.char/lt.pass.cpp
@@ -19,18 +19,18 @@
int main(int, char**)
{
- assert( std::char_traits<char>::lt('\0', 'A'));
- assert(!std::char_traits<char>::lt('A', '\0'));
+ assert(std::char_traits<char>::lt('\0', 'A') == ('\0' < 'A'));
+ assert(std::char_traits<char>::lt('A', '\0') == ('A' < '\0'));
- assert(!std::char_traits<char>::lt('a', 'a'));
- assert( std::char_traits<char>::lt('A', 'a'));
- assert(!std::char_traits<char>::lt('a', 'A'));
+ assert(std::char_traits<char>::lt('a', 'a') == ('a' < 'a'));
+ assert(std::char_traits<char>::lt('A', 'a') == ('A' < 'a'));
+ assert(std::char_traits<char>::lt('a', 'A') == ('a' < 'A'));
- assert( std::char_traits<char>::lt('a', 'z'));
- assert( std::char_traits<char>::lt('A', 'Z'));
+ assert(std::char_traits<char>::lt('a', 'z') == ('a' < 'z'));
+ assert(std::char_traits<char>::lt('A', 'Z') == ('A' < 'Z'));
- assert( std::char_traits<char>::lt(' ', 'A'));
- assert( std::char_traits<char>::lt('A', '~'));
+ assert(std::char_traits<char>::lt(' ', 'A') == (' ' < 'A'));
+ assert(std::char_traits<char>::lt('A', '~') == ('A' < '~'));
return 0;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D104748.354956.patch
Type: text/x-patch
Size: 2779 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20210628/3b8e38f1/attachment-0001.bin>
More information about the libcxx-commits
mailing list