[SystemZ][z/OS][libcxx]: fix libcxx test cases related to codecvt class UTF8

This PR to fix a few test cases related to class https://en.cppreference.com/w/cpp/locale/codecvt , as mentioned in document, class is converting UTF16 and UTF8 or UTF32 and UTF8, character type is deprecated in c++20 and it needs explicitly specify it is UTF8 string literal. Current test cases assume 1 byte character is ASCII or Unicode character which is not true on z/OS platform. UTF8/16/32 information can be found in https://naveenr.net/unicode-character-set-and-utf-8-utf-16-utf-32-encoding/ and EBCDIC and ASCII character value can be found in http://www.simotime.com/asc2ebc1.htm

Differential Revision: https://reviews.llvm.org/D106153
This commit is contained in:
Nancy Wang 2021-07-20 13:02:05 -04:00 committed by Muiez Ahmed
parent f3cb8d6e25
commit 7704fedfff
4 changed files with 8 additions and 0 deletions

View File

@ -17,6 +17,8 @@
// This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20. // This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20.
// ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS
// UNSUPPORTED: target={{.+}}-zos{{.*}}
#include <locale> #include <locale>
#include <string> #include <string>
#include <vector> #include <vector>

View File

@ -15,6 +15,8 @@
// This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20. // This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20.
// ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS
// UNSUPPORTED: target={{.+}}-zos{{.*}}
#include <locale> #include <locale>
#include <cassert> #include <cassert>

View File

@ -17,6 +17,8 @@
// This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20. // This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20.
// ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS
// UNSUPPORTED: target={{.+}}-zos{{.*}}
#include <locale> #include <locale>
#include <string> #include <string>
#include <vector> #include <vector>

View File

@ -15,6 +15,8 @@
// This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20. // This test runs in C++20, but we have deprecated codecvt<char(16|32), char, mbstate_t> in C++20.
// ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS // ADDITIONAL_COMPILE_FLAGS: -D_LIBCPP_DISABLE_DEPRECATION_WARNINGS
// UNSUPPORTED: target={{.+}}-zos{{.*}}
#include <locale> #include <locale>
#include <cassert> #include <cassert>