diff mbox series

[8/8] libstdc++: Remove unnecessary uses of _GLIBCXX_USE_WCHAR_T in testsuite [PR98725]

Message ID 20211009001351.659647-8-jwakely@redhat.com
State New
Headers show
Series [committed,1/8] libstdc++: Add missing _GLIBCXX_USE_WCHAR_T checks in testsuite | expand

Commit Message

Jonathan Wakely Oct. 9, 2021, 12:13 a.m. UTC
Now that std::wstring and other specializations for wchar_t are defined
unconditionally, many checks for _GLIBCXX_USE_WCHAR_T in the testsuite
are unnecessary and can be removed. Tests for iostreams, locales, regex
and filesystem::path still need to be guarded by _GLIBCXX_USE_WCHAR_T
because those components depend on libc support in <wchar.h> and other
headers.

libstdc++-v3/ChangeLog:

	PR libstdc++/98725
	* testsuite/18_support/numeric_limits/lowest.cc: Remove use of
	_GLIBCXX_USE_WCHAR_T.
	* testsuite/18_support/numeric_limits/min_max.cc: Replace use of
	_GLIBCXX_USE_WCHAR_T with checks for WCHAR_MIN and WCHAR_MAX.
	* testsuite/20_util/from_chars/1_neg.cc: Remove use of
	_GLIBCXX_USE_WCHAR_T.
	* testsuite/20_util/function_objects/searchers.cc: Likewise. Use
	char_traits<wchar_t>::length instead of wcslen.
	* testsuite/20_util/hash/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_arithmetic/value.cc: Likewise.
	* testsuite/20_util/is_compound/value.cc: Likewise.
	* testsuite/20_util/is_floating_point/value.cc: Likewise.
	* testsuite/20_util/is_fundamental/value.cc: Likewise.
	* testsuite/20_util/is_integral/value.cc: Likewise.
	* testsuite/20_util/is_signed/value.cc: Likewise.
	* testsuite/20_util/is_unsigned/value.cc: Likewise.
	* testsuite/20_util/is_void/value.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-1.cc:
	Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-2.cc:
	Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-3.cc:
	Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-4.cc:
	Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs-1.cc:
	Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
	Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs-3.cc:
	Likewise.
	* testsuite/20_util/to_chars/3.cc: Likewise.
	* testsuite/20_util/type_identity/requirements/typedefs.cc:
	Likewise.
	* testsuite/21_strings/basic_string/hash/debug.cc: Likewise.
	* testsuite/21_strings/basic_string/hash/hash.cc: Likewise.
	* testsuite/21_strings/basic_string/literals/types-char8_t.cc:
	Likewise.
	* testsuite/21_strings/basic_string/literals/types.cc: Likewise.
	* testsuite/21_strings/basic_string/literals/values-char8_t.cc:
	Likewise.
	* testsuite/21_strings/basic_string/literals/values.cc:
	Likewise.
	* testsuite/21_strings/basic_string/modifiers/64422.cc:
	Likewise.
	* testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
	Likewise.
	* testsuite/21_strings/basic_string/requirements/citerators.cc:
	Likewise.
	* testsuite/21_strings/basic_string/requirements/typedefs.cc:
	Likewise.
	* testsuite/21_strings/basic_string/types/pmr_typedefs.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/literals/types-char8_t.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/literals/types.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/literals/values-char8_t.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/literals/values.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/requirements/typedefs.cc:
	Likewise.
	* testsuite/21_strings/basic_string_view/typedefs.cc: Likewise.
	* testsuite/21_strings/char_traits/requirements/constexpr_functions.cc:
	Likewise.
	* testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc:
	Likewise.
	* testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc:
	Likewise.
	* testsuite/22_locale/ctype/is/string/89728_neg.cc: Likewise.
	* testsuite/25_algorithms/fill/4.cc: Likewise.
	* testsuite/25_algorithms/fill_n/1.cc: Likewise.
	* testsuite/experimental/functional/searchers.cc: Likewise. Use
	char_traits<wchar_t>::length instead of wcslen.
	* testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
	Likewise.
	* testsuite/experimental/string_view/literals/types-char8_t.cc:
	Likewise.
	* testsuite/experimental/string_view/literals/types.cc:
	Likewise.
	* testsuite/experimental/string_view/literals/values-char8_t.cc:
	Likewise.
	* testsuite/experimental/string_view/literals/values.cc:
	Likewise.
	* testsuite/experimental/string_view/range_access/wchar_t/1.cc:
	Likewise.
	* testsuite/experimental/string_view/requirements/typedefs.cc:
	Likewise.
	* testsuite/experimental/string_view/typedefs.cc: Likewise.
	* testsuite/ext/vstring/range_access.cc: Likewise.
	* testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc:
	Likewise.
	* testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc:
	Likewise.
	* testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_compound/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_floating_point/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_fundamental/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_integral/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_signed/value.cc: Likewise.
	* testsuite/tr1/4_metaprogramming/is_unsigned/value.cc:
	Likewise.
	* testsuite/tr1/4_metaprogramming/is_void/value.cc: Likewise.
	* testsuite/tr1/6_containers/hash/24799.cc: Likewise.
---
 .../testsuite/18_support/numeric_limits/lowest.cc      |  2 --
 .../testsuite/18_support/numeric_limits/min_max.cc     |  6 +++---
 libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc     |  4 ----
 .../testsuite/20_util/function_objects/searchers.cc    | 10 +++-------
 .../hash/requirements/explicit_instantiation.cc        |  3 ---
 libstdc++-v3/testsuite/20_util/is_arithmetic/value.cc  |  2 --
 libstdc++-v3/testsuite/20_util/is_compound/value.cc    |  2 --
 .../testsuite/20_util/is_floating_point/value.cc       |  2 --
 libstdc++-v3/testsuite/20_util/is_fundamental/value.cc |  4 +---
 libstdc++-v3/testsuite/20_util/is_integral/value.cc    |  4 +---
 libstdc++-v3/testsuite/20_util/is_signed/value.cc      |  6 ++----
 libstdc++-v3/testsuite/20_util/is_unsigned/value.cc    |  4 +---
 libstdc++-v3/testsuite/20_util/is_void/value.cc        |  4 +---
 .../20_util/make_signed/requirements/typedefs-1.cc     |  2 --
 .../20_util/make_signed/requirements/typedefs-2.cc     |  2 --
 .../20_util/make_signed/requirements/typedefs-3.cc     |  2 --
 .../20_util/make_signed/requirements/typedefs-4.cc     |  2 --
 .../20_util/make_unsigned/requirements/typedefs-1.cc   |  2 --
 .../20_util/make_unsigned/requirements/typedefs-2.cc   |  2 --
 .../20_util/make_unsigned/requirements/typedefs-3.cc   |  2 --
 libstdc++-v3/testsuite/20_util/to_chars/3.cc           |  2 --
 .../20_util/type_identity/requirements/typedefs.cc     |  3 ---
 .../testsuite/21_strings/basic_string/hash/debug.cc    |  2 --
 .../testsuite/21_strings/basic_string/hash/hash.cc     |  4 ----
 .../21_strings/basic_string/literals/types-char8_t.cc  |  2 --
 .../21_strings/basic_string/literals/types.cc          |  2 --
 .../21_strings/basic_string/literals/values-char8_t.cc |  4 ----
 .../21_strings/basic_string/literals/values.cc         |  4 ----
 .../21_strings/basic_string/modifiers/64422.cc         |  2 --
 .../21_strings/basic_string/range_access/wchar_t/1.cc  |  2 --
 .../21_strings/basic_string/requirements/citerators.cc |  2 --
 .../21_strings/basic_string/requirements/typedefs.cc   |  2 --
 .../21_strings/basic_string/types/pmr_typedefs.cc      |  2 --
 .../basic_string_view/literals/types-char8_t.cc        |  2 --
 .../21_strings/basic_string_view/literals/types.cc     |  2 --
 .../basic_string_view/literals/values-char8_t.cc       |  8 --------
 .../21_strings/basic_string_view/literals/values.cc    |  8 --------
 .../basic_string_view/requirements/typedefs.cc         |  2 --
 .../testsuite/21_strings/basic_string_view/typedefs.cc |  2 --
 .../char_traits/requirements/constexpr_functions.cc    |  4 +---
 .../requirements/constexpr_functions_c++17.cc          |  2 --
 .../requirements/constexpr_functions_c++20.cc          |  2 --
 .../testsuite/22_locale/ctype/is/string/89728_neg.cc   |  2 --
 libstdc++-v3/testsuite/25_algorithms/fill/4.cc         |  4 +---
 libstdc++-v3/testsuite/25_algorithms/fill_n/1.cc       |  4 +---
 .../testsuite/experimental/functional/searchers.cc     | 10 +++-------
 .../polymorphic_allocator/pmr_typedefs_string.cc       |  2 --
 .../experimental/string_view/literals/types-char8_t.cc |  2 --
 .../experimental/string_view/literals/types.cc         |  2 --
 .../string_view/literals/values-char8_t.cc             |  8 --------
 .../experimental/string_view/literals/values.cc        |  8 --------
 .../experimental/string_view/range_access/wchar_t/1.cc |  2 --
 .../experimental/string_view/requirements/typedefs.cc  |  2 --
 .../testsuite/experimental/string_view/typedefs.cc     |  3 ---
 libstdc++-v3/testsuite/ext/vstring/range_access.cc     |  2 --
 .../concepts.lang/concept.arithmetic/integral.cc       |  2 --
 .../concept.arithmetic/signed_integral.cc              |  2 --
 .../concept.arithmetic/unsigned_integral.cc            |  2 --
 .../tr1/4_metaprogramming/is_arithmetic/value.cc       |  2 --
 .../tr1/4_metaprogramming/is_compound/value.cc         |  2 --
 .../tr1/4_metaprogramming/is_floating_point/value.cc   |  2 --
 .../tr1/4_metaprogramming/is_fundamental/value.cc      |  2 --
 .../tr1/4_metaprogramming/is_integral/value.cc         |  2 --
 .../testsuite/tr1/4_metaprogramming/is_signed/value.cc |  2 --
 .../tr1/4_metaprogramming/is_unsigned/value.cc         |  2 --
 .../testsuite/tr1/4_metaprogramming/is_void/value.cc   |  2 --
 libstdc++-v3/testsuite/tr1/6_containers/hash/24799.cc  |  2 --
 67 files changed, 18 insertions(+), 189 deletions(-)
diff mbox series

Patch

diff --git a/libstdc++-v3/testsuite/18_support/numeric_limits/lowest.cc b/libstdc++-v3/testsuite/18_support/numeric_limits/lowest.cc
index b44dcf42826..54866966ee0 100644
--- a/libstdc++-v3/testsuite/18_support/numeric_limits/lowest.cc
+++ b/libstdc++-v3/testsuite/18_support/numeric_limits/lowest.cc
@@ -52,9 +52,7 @@  void test01()
   do_test<char>();
   do_test<signed char>();
   do_test<unsigned char>();
-#ifdef _GLIBCXX_USE_WCHAR_T
   do_test<wchar_t>();
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   do_test<char8_t>();
 #endif
diff --git a/libstdc++-v3/testsuite/18_support/numeric_limits/min_max.cc b/libstdc++-v3/testsuite/18_support/numeric_limits/min_max.cc
index f617e9399e2..6a76a93d3bb 100644
--- a/libstdc++-v3/testsuite/18_support/numeric_limits/min_max.cc
+++ b/libstdc++-v3/testsuite/18_support/numeric_limits/min_max.cc
@@ -48,9 +48,9 @@  DEFINE_EXTREMA(unsigned, 0U, UINT_MAX);
 DEFINE_EXTREMA(long, LONG_MIN, LONG_MAX);
 DEFINE_EXTREMA(unsigned long, 0UL, ULONG_MAX);
 
-#if _GLIBCXX_USE_WCHAR_T
+#if defined WCHAR_MIN && defined WCHAR_MAX
 DEFINE_EXTREMA(wchar_t, WCHAR_MIN, WCHAR_MAX);
-#endif //_GLIBCXX_USE_WCHAR_T
+#endif
 
 DEFINE_EXTREMA(float, FLT_MIN, FLT_MAX);
 DEFINE_EXTREMA(double, DBL_MIN, DBL_MAX);
@@ -74,7 +74,7 @@  int main()
   test_extrema<char>();
   test_extrema<signed char>();
   test_extrema<unsigned char>();
-  
+
   test_extrema<short>();
   test_extrema<unsigned short>();
 
diff --git a/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc b/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc
index 890cd826ee8..08bd63a854b 100644
--- a/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc
+++ b/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc
@@ -22,11 +22,7 @@ 
 void
 test01(const char* first, const char* last)
 {
-#if _GLIBCXX_USE_WCHAR_T
   wchar_t wc;
-#else
-  enum W { } wc;
-#endif
   std::from_chars(first, last, wc); // { dg-error "no matching" }
   std::from_chars(first, last, wc, 10); // { dg-error "no matching" }
 
diff --git a/libstdc++-v3/testsuite/20_util/function_objects/searchers.cc b/libstdc++-v3/testsuite/20_util/function_objects/searchers.cc
index f8899659cbe..bd32776a610 100644
--- a/libstdc++-v3/testsuite/20_util/function_objects/searchers.cc
+++ b/libstdc++-v3/testsuite/20_util/function_objects/searchers.cc
@@ -18,11 +18,9 @@ 
 // { dg-do run { target c++17 } }
 
 #include <functional>
+#include <string_view>
 #include <cstring>
 #include <cctype>
-#ifdef _GLIBCXX_USE_WCHAR_T
-# include <cwchar>
-#endif
 #include <algorithm>
 #include <testsuite_hooks.h>
 
@@ -84,7 +82,6 @@  test01()
 void
 test02()
 {
-#ifdef _GLIBCXX_USE_WCHAR_T
   const wchar_t s[] = { L'a', (wchar_t)-97, L'a', L'\0' };
   const wchar_t* needles[] = {
     s, L"", L"a", L"aa", L"aaa", L"ab", L"cd", L"abcd", L"abcdabcd", L"abcabcd"
@@ -96,14 +93,14 @@  test02()
 
   for (auto n : needles)
   {
-    auto nlen = std::wcslen(n);
+    auto nlen = std::char_traits<wchar_t>::length(n);
     auto ne = n + nlen;
     default_searcher d(n, ne);
     boyer_moore_searcher bm(n, ne);
     boyer_moore_horspool_searcher bmh(n, ne);
     for (auto h : haystacks)
     {
-      auto he = h + std::wcslen(h);
+      auto he = h + std::char_traits<wchar_t>::length(h);
       auto res = std::search(h, he, n, ne);
       auto d_res = d(h, he);
       VERIFY( d_res.first == res );
@@ -125,7 +122,6 @@  test02()
 	VERIFY( bmh_res.second == (bmh_res.first + nlen) );
     }
   }
-#endif
 }
 
 void
diff --git a/libstdc++-v3/testsuite/20_util/hash/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/hash/requirements/explicit_instantiation.cc
index 0f45ddbf0b3..9f76daae381 100644
--- a/libstdc++-v3/testsuite/20_util/hash/requirements/explicit_instantiation.cc
+++ b/libstdc++-v3/testsuite/20_util/hash/requirements/explicit_instantiation.cc
@@ -47,8 +47,5 @@  template class std::hash<std::error_code>;
 template class std::hash<std::error_condition>;
 #endif
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 template class std::hash<wchar_t>;
 template class std::hash<std::wstring>;
-#endif
-
diff --git a/libstdc++-v3/testsuite/20_util/is_arithmetic/value.cc b/libstdc++-v3/testsuite/20_util/is_arithmetic/value.cc
index 6cb5d42e2ce..644830a95d2 100644
--- a/libstdc++-v3/testsuite/20_util/is_arithmetic/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_arithmetic/value.cc
@@ -30,9 +30,7 @@  void test01()
   static_assert(test_category<is_arithmetic, char>(true), "");
   static_assert(test_category<is_arithmetic, signed char>(true), "");
   static_assert(test_category<is_arithmetic, unsigned char>(true), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_arithmetic, wchar_t>(true), "");
-#endif
   static_assert(test_category<is_arithmetic, short>(true), "");
   static_assert(test_category<is_arithmetic, unsigned short>(true), "");
   static_assert(test_category<is_arithmetic, int>(true), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_compound/value.cc b/libstdc++-v3/testsuite/20_util/is_compound/value.cc
index be2e1b99232..1ffa133b604 100644
--- a/libstdc++-v3/testsuite/20_util/is_compound/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_compound/value.cc
@@ -29,9 +29,7 @@  void test01()
   static_assert(test_category<is_compound, char>(false), "");
   static_assert(test_category<is_compound, signed char>(false), "");
   static_assert(test_category<is_compound, unsigned char>(false), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_compound, wchar_t>(false), "");
-#endif
   static_assert(test_category<is_compound, short>(false), "");
   static_assert(test_category<is_compound, unsigned short>(false), "");
   static_assert(test_category<is_compound, int>(false), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_floating_point/value.cc b/libstdc++-v3/testsuite/20_util/is_floating_point/value.cc
index c84351c706f..ad4aeeaa6c6 100644
--- a/libstdc++-v3/testsuite/20_util/is_floating_point/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_floating_point/value.cc
@@ -30,9 +30,7 @@  void test01()
   static_assert(test_category<is_floating_point, char>(false), "");
   static_assert(test_category<is_floating_point, signed char>(false), "");
   static_assert(test_category<is_floating_point, unsigned char>(false), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_floating_point, wchar_t>(false), "");
-#endif
   static_assert(test_category<is_floating_point, short>(false), "");
   static_assert(test_category<is_floating_point, unsigned short>(false), "");
   static_assert(test_category<is_floating_point, int>(false), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_fundamental/value.cc b/libstdc++-v3/testsuite/20_util/is_fundamental/value.cc
index cb2622eb52a..f3c7a7645f0 100644
--- a/libstdc++-v3/testsuite/20_util/is_fundamental/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_fundamental/value.cc
@@ -24,14 +24,12 @@  void test01()
 {
   using std::is_fundamental;
   using namespace __gnu_test;
-  
+
   static_assert(test_category<is_fundamental, void>(true), "");
   static_assert(test_category<is_fundamental, char>(true), "");
   static_assert(test_category<is_fundamental, signed char>(true), "");
   static_assert(test_category<is_fundamental, unsigned char>(true), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_fundamental, wchar_t>(true), "");
-#endif
   static_assert(test_category<is_fundamental, short>(true), "");
   static_assert(test_category<is_fundamental, unsigned short>(true), "");
   static_assert(test_category<is_fundamental, int>(true), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_integral/value.cc b/libstdc++-v3/testsuite/20_util/is_integral/value.cc
index 44962b55895..043601706fe 100644
--- a/libstdc++-v3/testsuite/20_util/is_integral/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_integral/value.cc
@@ -28,13 +28,11 @@  void test01()
   using namespace __gnu_test;
 
   static_assert(test_category<is_integral, void>(false), "");
-  
+
   static_assert(test_category<is_integral, char>(true), "");
   static_assert(test_category<is_integral, signed char>(true), "");
   static_assert(test_category<is_integral, unsigned char>(true), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_integral, wchar_t>(true), "");
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   static_assert(test_category<is_integral, char8_t>(true), "");
 #endif
diff --git a/libstdc++-v3/testsuite/20_util/is_signed/value.cc b/libstdc++-v3/testsuite/20_util/is_signed/value.cc
index 8d17e972090..cce9ac2a555 100644
--- a/libstdc++-v3/testsuite/20_util/is_signed/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_signed/value.cc
@@ -26,16 +26,14 @@  void test01()
 {
   using std::is_signed;
   using namespace __gnu_test;
-  
+
   static_assert(test_category<is_signed, void>(false), "");
-  
+
   static_assert(test_category<is_signed, char>(char(-1) < char(0)), "");
   static_assert(test_category<is_signed, signed char>(true), "");
   static_assert(test_category<is_signed, unsigned char>(false), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_signed, wchar_t>
 		(wchar_t(-1) < wchar_t(0)), "");
-#endif
   static_assert(test_category<is_signed, short>(true), "");
   static_assert(test_category<is_signed, unsigned short>(false), "");
   static_assert(test_category<is_signed, int>(true), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_unsigned/value.cc b/libstdc++-v3/testsuite/20_util/is_unsigned/value.cc
index d682220358b..37a52b8e99b 100644
--- a/libstdc++-v3/testsuite/20_util/is_unsigned/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_unsigned/value.cc
@@ -28,14 +28,12 @@  void test01()
   using namespace __gnu_test;
 
   static_assert(test_category<is_unsigned, void>(false), "");
-  
+
   static_assert(test_category<is_unsigned, char>(char(-1) > char(0)), "");
   static_assert(test_category<is_unsigned, signed char>(false), "");
   static_assert(test_category<is_unsigned, unsigned char>(true), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_unsigned, wchar_t>
 		(wchar_t(-1) > wchar_t(0)), "");
-#endif
   static_assert(test_category<is_unsigned, short>(false), "");
   static_assert(test_category<is_unsigned, unsigned short>(true), "");
   static_assert(test_category<is_unsigned, int>(false), "");
diff --git a/libstdc++-v3/testsuite/20_util/is_void/value.cc b/libstdc++-v3/testsuite/20_util/is_void/value.cc
index 45de4622633..31791a6119c 100644
--- a/libstdc++-v3/testsuite/20_util/is_void/value.cc
+++ b/libstdc++-v3/testsuite/20_util/is_void/value.cc
@@ -26,13 +26,11 @@  void test01()
   using namespace __gnu_test;
 
   static_assert(test_category<is_void, void>(true), "");
-  
+
   static_assert(test_category<is_void, char>(false), "");
   static_assert(test_category<is_void, signed char>(false), "");
   static_assert(test_category<is_void, unsigned char>(false), "");
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test_category<is_void, wchar_t>(false), "");
-#endif
   static_assert(test_category<is_void, short>(false), "");
   static_assert(test_category<is_void, unsigned short>(false), "");
   static_assert(test_category<is_void, int>(false), "");
diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-1.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-1.cc
index c010c9701df..ec6141b4db4 100644
--- a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-1.cc
+++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-1.cc
@@ -51,13 +51,11 @@  void test01()
   static_assert( is_same<test22_type, const signed char>::value,
                  "make_signed<const char>" );
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   typedef make_signed<volatile wchar_t>::type  	test23_type;
   static_assert( is_signed<test23_type>::value
                  && is_volatile<test23_type>::value
                  && sizeof(test23_type) == sizeof(volatile wchar_t),
                  "make_signed<volatile wchar_t>" );
-#endif
 
   // Chapter 48, chapter 20. Smallest rank such that new signed type same size.
   typedef make_signed<test_enum>::type  	test24_type;
diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-2.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-2.cc
index 0edf3d648b5..22685e03f30 100644
--- a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-2.cc
+++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-2.cc
@@ -49,12 +49,10 @@  void test01()
   typedef make_signed<const char>::type  	test22_type;
   static_assert(is_same<test22_type, const signed char>::value, "");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   typedef make_signed<volatile wchar_t>::type  	test23_type;
   static_assert(is_signed<test23_type>::value
                  && is_volatile<test23_type>::value
                  && sizeof(test23_type) == sizeof(volatile wchar_t), "");
-#endif
 
   typedef make_signed<test_enum>::type  	test24_type;
   static_assert(is_same<test24_type, short>::value, "");
diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-3.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-3.cc
index 32005128f59..b428e03a7b8 100644
--- a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-3.cc
+++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-3.cc
@@ -72,8 +72,6 @@  static_assert(is_same<make_signed<char16_t const>::type, I6 const>::value, "");
 using I7 = smallest_rank_t<char32_t>;
 static_assert(is_same<make_signed<char32_t>::type, I7>::value, "");
 static_assert(is_same<make_signed<char32_t const>::type, I7 const>::value, "");
-#ifdef _GLIBCXX_USE_WCHAR_T
 using I8 = smallest_rank_t<wchar_t>;
 static_assert(is_same<make_signed<wchar_t>::type, I8>::value, "");
 static_assert(is_same<make_signed<wchar_t const>::type, I8 const>::value, "");
-#endif
diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-4.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-4.cc
index eb4ec88b32a..55f0018d9df 100644
--- a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-4.cc
+++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs-4.cc
@@ -22,11 +22,9 @@ 
 // libstdc++/60326
 
 using namespace std;
-#ifdef _GLIBCXX_USE_WCHAR_T
 using wchar_signed = make_signed<wchar_t>::type;
 using wchar_unsigned = make_unsigned<wchar_t>::type;
 static_assert( !is_same<wchar_signed, wchar_unsigned>::value, "wchar_t" );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( is_signed<make_signed<char8_t>::type>::value, "char8_t");
 #endif
diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-1.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-1.cc
index e437c53cd8e..bb986930d9a 100644
--- a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-1.cc
+++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-1.cc
@@ -47,12 +47,10 @@  void test01()
   typedef make_unsigned<const char>::type  	test22_type;
   static_assert(is_same<test22_type, const unsigned char>::value, "");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   typedef make_unsigned<volatile wchar_t>::type  	test23_type;
   static_assert(is_unsigned<test23_type>::value
                 && is_volatile<test23_type>::value
                 && sizeof(test23_type) == sizeof(volatile wchar_t), "");
-#endif
 
   // Chapter 48, chapter 20. Smallest rank such that new unsigned type
   // same size.
diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-2.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-2.cc
index 7e2b8c459e7..5b4a1d4a249 100644
--- a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-2.cc
+++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-2.cc
@@ -49,12 +49,10 @@  void test01()
   typedef make_unsigned<const char>::type  	test22_type;
   static_assert(is_same<test22_type, const unsigned char>::value, "");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   typedef make_unsigned<volatile wchar_t>::type  	test23_type;
   static_assert(is_unsigned<test23_type>::value
                 && is_volatile<test23_type>::value
                 && sizeof(test23_type) == sizeof(volatile wchar_t), "");
-#endif
 
   typedef make_unsigned<test_enum>::type  	  test24_type;
   static_assert(is_same<test24_type, unsigned short>::value, "");
diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-3.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-3.cc
index 338ea304cad..737ec6fb0e0 100644
--- a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-3.cc
+++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs-3.cc
@@ -72,8 +72,6 @@  static_assert(is_same<make_unsigned<char16_t const>::type, I6 const>::value, "")
 using I7 = smallest_rank_t<char32_t>;
 static_assert(is_same<make_unsigned<char32_t>::type, I7>::value, "");
 static_assert(is_same<make_unsigned<char32_t const>::type, I7 const>::value, "");
-#ifdef _GLIBCXX_USE_WCHAR_T
 using I8 = smallest_rank_t<wchar_t>;
 static_assert(is_same<make_unsigned<wchar_t>::type, I8>::value, "");
 static_assert(is_same<make_unsigned<wchar_t const>::type, I8 const>::value, "");
-#endif
diff --git a/libstdc++-v3/testsuite/20_util/to_chars/3.cc b/libstdc++-v3/testsuite/20_util/to_chars/3.cc
index 30b02a53944..b40ba870382 100644
--- a/libstdc++-v3/testsuite/20_util/to_chars/3.cc
+++ b/libstdc++-v3/testsuite/20_util/to_chars/3.cc
@@ -48,9 +48,7 @@  test01()
 {
   VERIFY( check_to_chars(u'\x21') );
   VERIFY( check_to_chars(U'\x21') );
-#if _GLIBCXX_USE_WCHAR_T
   VERIFY( check_to_chars(L'\x21') );
-#endif
 }
 
 int main()
diff --git a/libstdc++-v3/testsuite/20_util/type_identity/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/type_identity/requirements/typedefs.cc
index 61f84118c63..cfdc716fad5 100644
--- a/libstdc++-v3/testsuite/20_util/type_identity/requirements/typedefs.cc
+++ b/libstdc++-v3/testsuite/20_util/type_identity/requirements/typedefs.cc
@@ -38,10 +38,7 @@  void test01()
   static_assert(test<volatile unsigned int>::value, "");
   static_assert(test<const volatile unsigned int>::value, "");
   static_assert(test<const unsigned char>::value, "");
-
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(test<volatile wchar_t>::value, "" );
-#endif
 
   // Pointers
   static_assert(test<void*>::value, "");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/hash/debug.cc b/libstdc++-v3/testsuite/21_strings/basic_string/hash/debug.cc
index 596bff9f8c6..59952e4e4b5 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/hash/debug.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/hash/debug.cc
@@ -43,9 +43,7 @@  test01()
 #endif
   VERIFY( test(__gnu_debug::u16string(u"a utf-16 string")) );
   VERIFY( test(__gnu_debug::u32string(U"a utf-32 string")) );
-#if _GLIBCXX_USE_WCHAR_T
   VERIFY( test(__gnu_debug::wstring(L"a wide string")) );
-#endif
 }
 
 #if _GLIBCXX_USE_CHAR8_T
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/hash/hash.cc b/libstdc++-v3/testsuite/21_strings/basic_string/hash/hash.cc
index e5d0a4dc5ee..2e739c02cef 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/hash/hash.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/hash/hash.cc
@@ -40,9 +40,7 @@  test01()
   VERIFY( test(std::string("a narrow string")) );
   VERIFY( test(std::u16string(u"a utf-16 string")) );
   VERIFY( test(std::u32string(U"a utf-32 string")) );
-#if _GLIBCXX_USE_WCHAR_T
   VERIFY( test(std::wstring(L"a wide string")) );
-#endif
 }
 
 void
@@ -52,10 +50,8 @@  test02()
   VERIFY( test(std::pmr::string("a narrow string, but with PMR!")) );
   VERIFY( test(std::pmr::u16string(u"a utf-16 string, but with PMR!")) );
   VERIFY( test(std::pmr::u32string(U"a utf-32 string, but with PMR!")) );
-#if _GLIBCXX_USE_WCHAR_T
   VERIFY( test(std::pmr::wstring(L"a wide string, but with PMR!")) );
 #endif
-#endif
 }
 
 int
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/literals/types-char8_t.cc b/libstdc++-v3/testsuite/21_strings/basic_string/literals/types-char8_t.cc
index 0ad6cafde28..e050b2ffe0d 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/literals/types-char8_t.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/literals/types-char8_t.cc
@@ -38,10 +38,8 @@  test01()
 #endif
 
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"s), std::wstring>::value,
 		"L\"Hello\"s is std::wstring");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"s), std::u16string>::value,
 		"u\"Hello\"s is std::u16string");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/literals/types.cc b/libstdc++-v3/testsuite/21_strings/basic_string/literals/types.cc
index a82f08ae847..3196fd338f9 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/literals/types.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/literals/types.cc
@@ -37,10 +37,8 @@  test01()
   static_assert(std::is_same<decltype(u8"Hello"s), u8string>::value,
 		"u8\"Hello\"s is std::string");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"s), std::wstring>::value,
 		"L\"Hello\"s is std::wstring");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"s), std::u16string>::value,
 		"u\"Hello\"s is std::u16string");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/literals/values-char8_t.cc b/libstdc++-v3/testsuite/21_strings/basic_string/literals/values-char8_t.cc
index 3b620c02619..cf6c9bc2100 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/literals/values-char8_t.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/literals/values-char8_t.cc
@@ -27,9 +27,7 @@  test01()
   using namespace std::literals::string_literals;
 
   std::string planet = "Mercury"s;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring wplanet = L"Venus"s;
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   std::u8string u8planet = u8"Mars"s;
 #else
@@ -39,9 +37,7 @@  test01()
   std::u32string u32planet = U"Saturn"s;
 
   VERIFY( planet == std::string("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::wstring(L"Venus") );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   VERIFY( u8planet == std::u8string(u8"Mars") );
 #else
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/literals/values.cc b/libstdc++-v3/testsuite/21_strings/basic_string/literals/values.cc
index 9e15cacbdb4..8057b3e33e1 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/literals/values.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/literals/values.cc
@@ -32,17 +32,13 @@  test01()
   using namespace std::literals::string_literals;
 
   std::string planet = "Mercury"s;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring wplanet = L"Venus"s;
-#endif
   u8string u8planet = u8"Mars"s;
   std::u16string u16planet = u"Jupiter"s;
   std::u32string u32planet = U"Saturn"s;
 
   VERIFY( planet == std::string("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::wstring(L"Venus") );
-#endif
   VERIFY( u8planet == u8string(u8"Mars") );
   VERIFY( u16planet == std::u16string(u"Jupiter") );
   VERIFY( u32planet == std::u32string(U"Saturn") );
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/64422.cc b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/64422.cc
index 9a3ad724c96..2cdd3084363 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/64422.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/64422.cc
@@ -34,7 +34,6 @@  main ()
   x.replace (x.begin (), x.end (), best, best + 4);
   x.replace (x.begin (), x.end (), x);
   x.erase (x.begin (), x.end ());
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring w;
   w.insert (w.begin (), 10, L'x');
   const wchar_t west[] = L"west";
@@ -44,6 +43,5 @@  main ()
   w.replace (w.begin (), w.end (), rest, rest + 4);
   w.replace (w.begin (), w.end (), w);
   w.erase (w.begin (), w.end ());
-#endif
   return 0;
 }
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/range_access/wchar_t/1.cc b/libstdc++-v3/testsuite/21_strings/basic_string/range_access/wchar_t/1.cc
index 56169150089..c307b1a1479 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/range_access/wchar_t/1.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/range_access/wchar_t/1.cc
@@ -24,9 +24,7 @@ 
 void
 test01()
 {
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring ws(L"Hello, World!");
   (void) std::begin(ws);
   (void) std::end(ws);
-#endif
 }
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/requirements/citerators.cc b/libstdc++-v3/testsuite/21_strings/basic_string/requirements/citerators.cc
index fca2a8940e9..c7d22f22bde 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/requirements/citerators.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/requirements/citerators.cc
@@ -27,9 +27,7 @@  int main()
 {
   __gnu_test::citerator<std::string> test1;
   __gnu_test::citerator<__gnu_debug::string> dtest1;
-#ifdef _GLIBCXX_USE_WCHAR_T
   __gnu_test::citerator<std::wstring> test2;
   __gnu_test::citerator<__gnu_debug::wstring> dtest2;
-#endif
   return 0;
 }
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/requirements/typedefs.cc b/libstdc++-v3/testsuite/21_strings/basic_string/requirements/typedefs.cc
index ff5f98e7805..33f35304e98 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/requirements/typedefs.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/requirements/typedefs.cc
@@ -24,7 +24,5 @@ 
 // Check container for required typedefs.
 __gnu_test::types<std::string> t1;
 __gnu_test::types<__gnu_debug::string> dt1;
-#ifdef _GLIBCXX_USE_WCHAR_T
 __gnu_test::types<std::wstring> t2;
 __gnu_test::types<__gnu_debug::wstring> dt2;
-#endif
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/types/pmr_typedefs.cc b/libstdc++-v3/testsuite/21_strings/basic_string/types/pmr_typedefs.cc
index cb597a74312..7b383fc534e 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string/types/pmr_typedefs.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string/types/pmr_typedefs.cc
@@ -44,7 +44,6 @@  static_assert(std::is_same_v<std::pmr::u32string,
     std::basic_string<char32_t, std::char_traits<char32_t>,
 		      std::pmr::polymorphic_allocator<char32_t>>>);
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert(std::is_same_v<std::pmr::basic_string<wchar_t>,
     std::basic_string<wchar_t, std::char_traits<wchar_t>,
 		      std::pmr::polymorphic_allocator<wchar_t>>>);
@@ -54,4 +53,3 @@  static_assert(std::is_same_v<std::pmr::basic_string<wchar_t, T>,
 static_assert(std::is_same_v<std::pmr::wstring,
     std::basic_string<wchar_t, std::char_traits<wchar_t>,
 		      std::pmr::polymorphic_allocator<wchar_t>>>);
-#endif
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types-char8_t.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types-char8_t.cc
index 60713667c91..6c5c1aa5d4f 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types-char8_t.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types-char8_t.cc
@@ -37,10 +37,8 @@  test01()
 		"u8\"Hello\"sv is std::string_view");
 #endif
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"sv), std::wstring_view>::value,
 		"L\"Hello\"sv is std::wstring_view");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"sv), std::u16string_view>::value,
 		"u\"Hello\"sv is std::u16string_view");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types.cc
index 8a562f0cf11..851501d6734 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/types.cc
@@ -37,10 +37,8 @@  test01()
   static_assert(std::is_same<decltype(u8"Hello"sv), u8string_view>::value,
 		"u8\"Hello\"s is std::string_view");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"sv), std::wstring_view>::value,
 		"L\"Hello\"s is std::wstring_view");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"sv), std::u16string_view>::value,
 		"u\"Hello\"s is std::u16string_view");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values-char8_t.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values-char8_t.cc
index 04550d6e669..54e8cb25b11 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values-char8_t.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values-char8_t.cc
@@ -27,9 +27,7 @@  test01()
   using namespace std::literals::string_view_literals;
 
   std::string_view planet = "Mercury"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring_view wplanet = L"Venus"sv;
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   std::u8string_view u8planet = u8"Mars"sv;
 #else
@@ -39,9 +37,7 @@  test01()
   std::u32string_view u32planet = U"Saturn"sv;
 
   VERIFY( planet == std::string_view("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::wstring_view(L"Venus") );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   VERIFY( u8planet == std::u8string_view(u8"Mars") );
 #else
@@ -57,9 +53,7 @@  test02()
   using namespace std::literals::string_view_literals;
 
   std::string_view planet_cratered = "Mercury\0cratered"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring_view wplanet_cratered = L"Venus\0cratered"sv;
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   std::u8string_view u8planet_cratered = u8"Mars\0cratered"sv;
 #else
@@ -69,9 +63,7 @@  test02()
   std::u32string_view u32planet_cratered = U"Saturn\0cratered"sv;
 
   VERIFY( planet_cratered == std::string_view("Mercury\0cratered", 16) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet_cratered == std::wstring_view(L"Venus\0cratered", 14) );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   VERIFY( u8planet_cratered == std::u8string_view(u8"Mars\0cratered", 13) );
 #else
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values.cc
index 79033d8d7ea..28e648ff764 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/literals/values.cc
@@ -32,17 +32,13 @@  test01()
   using namespace std::literals::string_view_literals;
 
   std::string_view planet = "Mercury"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring_view wplanet = L"Venus"sv;
-#endif
   u8string_view u8planet = u8"Mars"sv;
   std::u16string_view u16planet = u"Jupiter"sv;
   std::u32string_view u32planet = U"Saturn"sv;
 
   VERIFY( planet == std::string_view("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::wstring_view(L"Venus") );
-#endif
   VERIFY( u8planet == u8string_view(u8"Mars") );
   VERIFY( u16planet == std::u16string_view(u"Jupiter") );
   VERIFY( u32planet == std::u32string_view(U"Saturn") );
@@ -54,17 +50,13 @@  test02()
   using namespace std::literals::string_view_literals;
 
   std::string_view planet_cratered = "Mercury\0cratered"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::wstring_view wplanet_cratered = L"Venus\0cratered"sv;
-#endif
   u8string_view u8planet_cratered = u8"Mars\0cratered"sv;
   std::u16string_view u16planet_cratered = u"Jupiter\0cratered"sv;
   std::u32string_view u32planet_cratered = U"Saturn\0cratered"sv;
 
   VERIFY( planet_cratered == std::string_view("Mercury\0cratered", 16) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet_cratered == std::wstring_view(L"Venus\0cratered", 14) );
-#endif
   VERIFY( u8planet_cratered == u8string_view(u8"Mars\0cratered", 13) );
   VERIFY( u16planet_cratered == std::u16string_view(u"Jupiter\0cratered", 16) );
   VERIFY( u32planet_cratered == std::u32string_view(U"Saturn\0cratered", 15) );
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/requirements/typedefs.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/requirements/typedefs.cc
index a3282fb0323..c75029a022a 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/requirements/typedefs.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/requirements/typedefs.cc
@@ -39,11 +39,9 @@  __gnu_test::basic_types<std::string_view> t1b;
 __gnu_test::reversible_types<std::string_view> t1r;
 typedef typename std::string_view::traits_type traits_type1;
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 __gnu_test::basic_types<std::wstring_view> t2b;
 __gnu_test::reversible_types<std::wstring_view> t2r;
 typedef typename std::wstring_view::traits_type traits_type2;
-#endif
 
 static_assert(std::is_same<std::string_view::pointer, char*>(),
     "pointer should be value_type*");
diff --git a/libstdc++-v3/testsuite/21_strings/basic_string_view/typedefs.cc b/libstdc++-v3/testsuite/21_strings/basic_string_view/typedefs.cc
index 26cbc203501..b14610d452c 100644
--- a/libstdc++-v3/testsuite/21_strings/basic_string_view/typedefs.cc
+++ b/libstdc++-v3/testsuite/21_strings/basic_string_view/typedefs.cc
@@ -33,6 +33,4 @@  using check4_t = std::u16string_view;
 using check5_t = std::u32string_view;
 #endif
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 using check6_t = std::wstring_view;
-#endif
diff --git a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions.cc b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions.cc
index 827b6a24e3c..8bfac4af220 100644
--- a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions.cc
+++ b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions.cc
@@ -31,7 +31,7 @@  namespace __gnu_test
 	struct _Concept
 	{
 	  void __constraint()
-	  { 
+	  {
 	    typedef typename _Ttesttype::char_type char_type;
 	    typedef typename _Ttesttype::int_type int_type;
 	    const char_type c1(0);
@@ -64,9 +64,7 @@  int main()
 {
   __gnu_test::constexpr_member_functions test;
   test.operator()<std::char_traits<char>>();
-#ifdef _GLIBCXX_USE_WCHAR_T
   test.operator()<std::char_traits<wchar_t>>();
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   test.operator()<std::char_traits<char8_t>>();
 #endif
diff --git a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc
index 7db31031b8a..fa82be2fc58 100644
--- a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc
+++ b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++17.cc
@@ -89,12 +89,10 @@  static_assert( test_assign<std::char_traits<char>>() );
 static_assert( test_compare<std::char_traits<char>>() );
 static_assert( test_length<std::char_traits<char>>() );
 static_assert( test_find<std::char_traits<char>>() );
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert( test_assign<std::char_traits<wchar_t>>() );
 static_assert( test_compare<std::char_traits<wchar_t>>() );
 static_assert( test_length<std::char_traits<wchar_t>>() );
 static_assert( test_find<std::char_traits<wchar_t>>() );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( test_assign<std::char_traits<char8_t>>() );
 static_assert( test_compare<std::char_traits<char8_t>>() );
diff --git a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc
index 0d1595fe030..0577cb1c0bc 100644
--- a/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc
+++ b/libstdc++-v3/testsuite/21_strings/char_traits/requirements/constexpr_functions_c++20.cc
@@ -44,9 +44,7 @@  template<typename CT>
 #endif
 
 static_assert( test_move<std::char_traits<char>>() );
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert( test_move<std::char_traits<wchar_t>>() );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( test_move<std::char_traits<char8_t>>() );
 #endif
diff --git a/libstdc++-v3/testsuite/22_locale/ctype/is/string/89728_neg.cc b/libstdc++-v3/testsuite/22_locale/ctype/is/string/89728_neg.cc
index 89843b68494..71772427815 100644
--- a/libstdc++-v3/testsuite/22_locale/ctype/is/string/89728_neg.cc
+++ b/libstdc++-v3/testsuite/22_locale/ctype/is/string/89728_neg.cc
@@ -52,7 +52,6 @@  void test01()
   std::tolower(make_str<char, 12>(), loc);	// { dg-error "required from here" }
 }
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 void test02()
 {
   const std::locale& loc = std::locale::classic();
@@ -74,4 +73,3 @@  void test02()
   std::toupper(make_str<wchar_t, 11>(), loc);	// { dg-error "required from here" }
   std::tolower(make_str<wchar_t, 12>(), loc);	// { dg-error "required from here" }
 }
-#endif
diff --git a/libstdc++-v3/testsuite/25_algorithms/fill/4.cc b/libstdc++-v3/testsuite/25_algorithms/fill/4.cc
index 5c761c46b9c..1b2402d36cb 100644
--- a/libstdc++-v3/testsuite/25_algorithms/fill/4.cc
+++ b/libstdc++-v3/testsuite/25_algorithms/fill/4.cc
@@ -30,7 +30,7 @@  test01()
 
   const int A1[] = {3, 3, 3, 3, 3, 3, 3, 3, 3, 3};
   const int N1 = sizeof(A1) / sizeof(int);
-  
+
   int i1[N1];
   fill(i1, i1 + N1, 3);
   VERIFY( equal(i1, i1 + N1, A1) );
@@ -51,7 +51,6 @@  test01()
   fill(v2.begin(), v2.end(), '\3');
   VERIFY( equal(v2.begin(), v2.end(), A2) );
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   const wchar_t A3[] = {L'\3', L'\3', L'\3', L'\3', L'\3',
 			L'\3', L'\3', L'\3', L'\3', L'\3'};
   const int N3 = sizeof(A3) / sizeof(wchar_t);
@@ -63,7 +62,6 @@  test01()
   vector<wchar_t> v3(N3);
   fill(v3.begin(), v3.end(), L'\3');
   VERIFY( equal(v3.begin(), v3.end(), A3) );
-#endif
 }
 
 int
diff --git a/libstdc++-v3/testsuite/25_algorithms/fill_n/1.cc b/libstdc++-v3/testsuite/25_algorithms/fill_n/1.cc
index 744856b06c0..893aa5b4ebf 100644
--- a/libstdc++-v3/testsuite/25_algorithms/fill_n/1.cc
+++ b/libstdc++-v3/testsuite/25_algorithms/fill_n/1.cc
@@ -44,7 +44,7 @@  test01()
 
   const int A1[] = {3, 3, 3, 3, 3, 3, 3, 3, 3, 3};
   const int N1 = sizeof(A1) / sizeof(int);
-  
+
   int i1[N1];
   test_container<int, output_iterator_wrapper> c1(i1, i1 + N1);
   fill_n(c1.begin(), N1, 3);
@@ -66,7 +66,6 @@  test01()
   fill_n(v2.begin(), N2, '\3');
   VERIFY( equal(v2.begin(), v2.end(), A2) );
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   const wchar_t A3[] = {L'\3', L'\3', L'\3', L'\3', L'\3',
 			L'\3', L'\3', L'\3', L'\3', L'\3'};
   const int N3 = sizeof(A3) / sizeof(wchar_t);
@@ -78,7 +77,6 @@  test01()
   vector<wchar_t> v3(N3);
   fill_n(v3.begin(), N3, L'\3');
   VERIFY( equal(v3.begin(), v3.end(), A3) );
-#endif
 }
 
 int
diff --git a/libstdc++-v3/testsuite/experimental/functional/searchers.cc b/libstdc++-v3/testsuite/experimental/functional/searchers.cc
index 929181871ad..050d03c74c2 100644
--- a/libstdc++-v3/testsuite/experimental/functional/searchers.cc
+++ b/libstdc++-v3/testsuite/experimental/functional/searchers.cc
@@ -18,10 +18,8 @@ 
 // { dg-do run { target c++14 } }
 
 #include <experimental/functional>
+#include <experimental/string_view>
 #include <cstring>
-#ifdef _GLIBCXX_USE_WCHAR_T
-# include <cwchar>
-#endif
 #include <algorithm>
 #include <testsuite_hooks.h>
 
@@ -64,7 +62,6 @@  test01()
 void
 test02()
 {
-#ifdef _GLIBCXX_USE_WCHAR_T
   const wchar_t s[] = { L'a', (wchar_t)-97, L'a', L'\0' };
   const wchar_t* needles[] = {
     s, L"", L"a", L"aa", L"aaa", L"ab", L"cd", L"abcd", L"abcdabcd", L"abcabcd"
@@ -76,13 +73,13 @@  test02()
 
   for (auto n : needles)
   {
-    auto ne = n + std::wcslen(n);
+    auto ne = n + std::char_traits<wchar_t>::length(n);
     auto d = make_default_searcher(n, ne);
     auto bm = make_boyer_moore_searcher(n, ne);
     auto bmh = make_boyer_moore_horspool_searcher(n, ne);
     for (auto h : haystacks)
     {
-      auto he = h + std::wcslen(h);
+      auto he = h + std::char_traits<wchar_t>::length(h);
       auto res = std::search(h, he, n, ne);
       auto d_res = d(h, he);
       VERIFY( d_res == res );
@@ -92,7 +89,6 @@  test02()
       VERIFY( bmh_res == res );
     }
   }
-#endif
 }
 
 void
diff --git a/libstdc++-v3/testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc b/libstdc++-v3/testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc
index f57f334da26..a73e0b6675d 100644
--- a/libstdc++-v3/testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc
+++ b/libstdc++-v3/testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc
@@ -51,7 +51,6 @@  static_assert(std::is_same<xpmr::u32string,
 		      xpmr::polymorphic_allocator<char32_t>>>::value,
     "pmr::u32string");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert(std::is_same<xpmr::basic_string<wchar_t>,
     std::basic_string<wchar_t, std::char_traits<wchar_t>,
 		      xpmr::polymorphic_allocator<wchar_t>>>::value,
@@ -64,4 +63,3 @@  static_assert(std::is_same<xpmr::wstring,
     std::basic_string<wchar_t, std::char_traits<wchar_t>,
 		      xpmr::polymorphic_allocator<wchar_t>>>::value,
     "pmr::wstring");
-#endif
diff --git a/libstdc++-v3/testsuite/experimental/string_view/literals/types-char8_t.cc b/libstdc++-v3/testsuite/experimental/string_view/literals/types-char8_t.cc
index 649a428250c..1d320961f84 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/literals/types-char8_t.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/literals/types-char8_t.cc
@@ -37,10 +37,8 @@  test01()
 		"u8\"Hello\"sv is std::string_view");
 #endif
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"sv), std::experimental::wstring_view>::value,
 		"L\"Hello\"sv is std::wstring_view");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"sv), std::experimental::u16string_view>::value,
 		"u\"Hello\"sv is std::u16string_view");
diff --git a/libstdc++-v3/testsuite/experimental/string_view/literals/types.cc b/libstdc++-v3/testsuite/experimental/string_view/literals/types.cc
index 20b166acfe6..f9d2fc970b1 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/literals/types.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/literals/types.cc
@@ -37,10 +37,8 @@  test01()
   static_assert(std::is_same<decltype(u8"Hello"sv), u8string_view>::value,
 		"u8\"Hello\"s is std::string_view");
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   static_assert(std::is_same<decltype(L"Hello"sv), std::experimental::wstring_view>::value,
 		"L\"Hello\"s is std::wstring_view");
-#endif
 
   static_assert(std::is_same<decltype(u"Hello"sv), std::experimental::u16string_view>::value,
 		"u\"Hello\"s is std::u16string_view");
diff --git a/libstdc++-v3/testsuite/experimental/string_view/literals/values-char8_t.cc b/libstdc++-v3/testsuite/experimental/string_view/literals/values-char8_t.cc
index 3fddcdcc3f9..1a8d906014f 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/literals/values-char8_t.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/literals/values-char8_t.cc
@@ -27,9 +27,7 @@  test01()
   using namespace std::experimental::literals::string_view_literals;
 
   std::experimental::string_view planet = "Mercury"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::experimental::wstring_view wplanet = L"Venus"sv;
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   std::experimental::u8string_view u8planet = u8"Mars"sv;
 #else
@@ -39,9 +37,7 @@  test01()
   std::experimental::u32string_view u32planet = U"Saturn"sv;
 
   VERIFY( planet == std::experimental::string_view("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::experimental::wstring_view(L"Venus") );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   VERIFY( u8planet == std::experimental::u8string_view(u8"Mars") );
 #else
@@ -57,9 +53,7 @@  test02()
   using namespace std::experimental::literals::string_view_literals;
 
   std::experimental::string_view planet_cratered = "Mercury\0cratered"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::experimental::wstring_view wplanet_cratered = L"Venus\0cratered"sv;
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   std::experimental::u8string_view u8planet_cratered = u8"Mars\0cratered"sv;
 #else
@@ -70,10 +64,8 @@  test02()
 
   VERIFY( planet_cratered ==
 	  std::experimental::string_view("Mercury\0cratered", 16) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet_cratered ==
 	  std::experimental::wstring_view(L"Venus\0cratered", 14) );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
   VERIFY( u8planet_cratered ==
 	  std::experimental::u8string_view(u8"Mars\0cratered", 13) );
diff --git a/libstdc++-v3/testsuite/experimental/string_view/literals/values.cc b/libstdc++-v3/testsuite/experimental/string_view/literals/values.cc
index 05bca73bce4..8e1770507e2 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/literals/values.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/literals/values.cc
@@ -32,17 +32,13 @@  test01()
   using namespace std::experimental::literals::string_view_literals;
 
   std::experimental::string_view planet = "Mercury"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::experimental::wstring_view wplanet = L"Venus"sv;
-#endif
   u8string_view u8planet = u8"Mars"sv;
   std::experimental::u16string_view u16planet = u"Jupiter"sv;
   std::experimental::u32string_view u32planet = U"Saturn"sv;
 
   VERIFY( planet == std::experimental::string_view("Mercury") );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet == std::experimental::wstring_view(L"Venus") );
-#endif
   VERIFY( u8planet == u8string_view(u8"Mars") );
   VERIFY( u16planet == std::experimental::u16string_view(u"Jupiter") );
   VERIFY( u32planet == std::experimental::u32string_view(U"Saturn") );
@@ -54,19 +50,15 @@  test02()
   using namespace std::experimental::literals::string_view_literals;
 
   std::experimental::string_view planet_cratered = "Mercury\0cratered"sv;
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::experimental::wstring_view wplanet_cratered = L"Venus\0cratered"sv;
-#endif
   u8string_view u8planet_cratered = u8"Mars\0cratered"sv;
   std::experimental::u16string_view u16planet_cratered = u"Jupiter\0cratered"sv;
   std::experimental::u32string_view u32planet_cratered = U"Saturn\0cratered"sv;
 
   VERIFY( planet_cratered ==
 	  std::experimental::string_view("Mercury\0cratered", 16) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( wplanet_cratered ==
 	  std::experimental::wstring_view(L"Venus\0cratered", 14) );
-#endif
   VERIFY( u8planet_cratered == u8string_view(u8"Mars\0cratered", 13) );
   VERIFY( u16planet_cratered ==
 	  std::experimental::u16string_view(u"Jupiter\0cratered", 16) );
diff --git a/libstdc++-v3/testsuite/experimental/string_view/range_access/wchar_t/1.cc b/libstdc++-v3/testsuite/experimental/string_view/range_access/wchar_t/1.cc
index f19e455a606..920574668a1 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/range_access/wchar_t/1.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/range_access/wchar_t/1.cc
@@ -24,9 +24,7 @@ 
 void
 test01()
 {
-#ifdef _GLIBCXX_USE_WCHAR_T
   std::experimental::wstring_view ws(L"Hello, World!");
   (void) std::begin(ws);
   (void) std::end(ws);
-#endif
 }
diff --git a/libstdc++-v3/testsuite/experimental/string_view/requirements/typedefs.cc b/libstdc++-v3/testsuite/experimental/string_view/requirements/typedefs.cc
index 4bd30584a16..bc9dec02611 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/requirements/typedefs.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/requirements/typedefs.cc
@@ -38,11 +38,9 @@  __gnu_test::basic_types<std::experimental::string_view> t1b;
 __gnu_test::reversible_types<std::experimental::string_view> t1r;
 typedef typename std::experimental::string_view::traits_type traits_type1;
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 __gnu_test::basic_types<std::experimental::wstring_view> t2b;
 __gnu_test::reversible_types<std::experimental::wstring_view> t2r;
 typedef typename std::experimental::wstring_view::traits_type traits_type2;
-#endif
 
 static_assert(
     std::is_same<std::experimental::string_view::pointer, char*>(),
diff --git a/libstdc++-v3/testsuite/experimental/string_view/typedefs.cc b/libstdc++-v3/testsuite/experimental/string_view/typedefs.cc
index fd32c562765..c6290f8c198 100644
--- a/libstdc++-v3/testsuite/experimental/string_view/typedefs.cc
+++ b/libstdc++-v3/testsuite/experimental/string_view/typedefs.cc
@@ -33,7 +33,4 @@  using check4_t = std::experimental::fundamentals_v1::u16string_view;
 using check5_t = std::experimental::fundamentals_v1::u32string_view;
 #endif
 
-#ifdef _GLIBCXX_USE_WCHAR_T
 using check6_t = std::experimental::fundamentals_v1::wstring_view;
-#endif
-
diff --git a/libstdc++-v3/testsuite/ext/vstring/range_access.cc b/libstdc++-v3/testsuite/ext/vstring/range_access.cc
index 7b381ffd956..3876b80d50d 100644
--- a/libstdc++-v3/testsuite/ext/vstring/range_access.cc
+++ b/libstdc++-v3/testsuite/ext/vstring/range_access.cc
@@ -28,9 +28,7 @@  test01()
   (void) std::begin(s);
   (void) std::end(s);
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   __gnu_cxx::__wvstring ws(L"Hello, World!");
   (void) std::begin(ws);
   (void) std::end(ws);
-#endif
 }
diff --git a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc
index 8c937adf251..c206b9bb1fa 100644
--- a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc
+++ b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/integral.cc
@@ -39,9 +39,7 @@  static_assert( std::integral<bool> );
 static_assert( std::integral<char> );
 static_assert( std::integral<char16_t> );
 static_assert( std::integral<char32_t> );
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert( std::integral<wchar_t> );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( std::integral<char8_t> );
 #endif
diff --git a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc
index ec6fddc68b3..bf067e39f62 100644
--- a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc
+++ b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/signed_integral.cc
@@ -39,9 +39,7 @@  static_assert( !std::signed_integral<bool> );
 static_assert( std::is_signed_v<char> ? std::signed_integral<char> : true );
 static_assert( !std::signed_integral<char16_t> );
 static_assert( !std::signed_integral<char32_t> );
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert( std::is_signed_v<wchar_t> ? std::signed_integral<wchar_t> : true );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( !std::signed_integral<char8_t> );
 #endif
diff --git a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc
index 59f233ae791..e6b7c5ee701 100644
--- a/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc
+++ b/libstdc++-v3/testsuite/std/concepts/concepts.lang/concept.arithmetic/unsigned_integral.cc
@@ -39,9 +39,7 @@  static_assert( std::unsigned_integral<bool> );
 static_assert( std::is_signed_v<char> ? true : std::unsigned_integral<char> );
 static_assert( std::unsigned_integral<char16_t> );
 static_assert( std::unsigned_integral<char32_t> );
-#ifdef _GLIBCXX_USE_WCHAR_T
 static_assert( std::is_signed_v<wchar_t> ? true : std::unsigned_integral<wchar_t> );
-#endif
 #ifdef _GLIBCXX_USE_CHAR8_T
 static_assert( std::unsigned_integral<char8_t> );
 #endif
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc
index 0b8de065a89..df5f0c5771b 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc
@@ -33,9 +33,7 @@  void test01()
   VERIFY( (test_category<is_arithmetic, char>(true)) );
   VERIFY( (test_category<is_arithmetic, signed char>(true)) );
   VERIFY( (test_category<is_arithmetic, unsigned char>(true)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_arithmetic, wchar_t>(true)) );
-#endif
   VERIFY( (test_category<is_arithmetic, short>(true)) );
   VERIFY( (test_category<is_arithmetic, unsigned short>(true)) );
   VERIFY( (test_category<is_arithmetic, int>(true)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc
index 8c7520dca5e..3f89cb533c0 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc
@@ -32,9 +32,7 @@  void test01()
   VERIFY( (test_category<is_compound, char>(false)) );
   VERIFY( (test_category<is_compound, signed char>(false)) );
   VERIFY( (test_category<is_compound, unsigned char>(false)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_compound, wchar_t>(false)) );
-#endif
   VERIFY( (test_category<is_compound, short>(false)) );
   VERIFY( (test_category<is_compound, unsigned short>(false)) );
   VERIFY( (test_category<is_compound, int>(false)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc
index e4e8b86dc73..a5aa1460597 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc
@@ -32,9 +32,7 @@  void test01()
   VERIFY( (test_category<is_floating_point, char>(false)) );
   VERIFY( (test_category<is_floating_point, signed char>(false)) );
   VERIFY( (test_category<is_floating_point, unsigned char>(false)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_floating_point, wchar_t>(false)) );
-#endif
   VERIFY( (test_category<is_floating_point, short>(false)) );
   VERIFY( (test_category<is_floating_point, unsigned short>(false)) );
   VERIFY( (test_category<is_floating_point, int>(false)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc
index 0628977e011..0c30b35e0b7 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc
@@ -32,9 +32,7 @@  void test01()
   VERIFY( (test_category<is_fundamental, char>(true)) );
   VERIFY( (test_category<is_fundamental, signed char>(true)) );
   VERIFY( (test_category<is_fundamental, unsigned char>(true)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_fundamental, wchar_t>(true)) );
-#endif
   VERIFY( (test_category<is_fundamental, short>(true)) );
   VERIFY( (test_category<is_fundamental, unsigned short>(true)) );
   VERIFY( (test_category<is_fundamental, int>(true)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc
index e4dba6d6211..8866b7cb455 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc
@@ -33,9 +33,7 @@  void test01()
   VERIFY( (test_category<is_integral, char>(true)) );
   VERIFY( (test_category<is_integral, signed char>(true)) );
   VERIFY( (test_category<is_integral, unsigned char>(true)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_integral, wchar_t>(true)) );
-#endif
   VERIFY( (test_category<is_integral, short>(true)) );
   VERIFY( (test_category<is_integral, unsigned short>(true)) );
   VERIFY( (test_category<is_integral, int>(true)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc
index a96b64f4003..82ab7a5dbde 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc
@@ -33,9 +33,7 @@  void test01()
   VERIFY( (test_category<is_signed, char>(false)) );
   VERIFY( (test_category<is_signed, signed char>(true)) );
   VERIFY( (test_category<is_signed, unsigned char>(false)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_signed, wchar_t>(false)) );
-#endif
   VERIFY( (test_category<is_signed, short>(true)) );
   VERIFY( (test_category<is_signed, unsigned short>(false)) );
   VERIFY( (test_category<is_signed, int>(true)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc
index 3d9822507b3..41c6682cff1 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc
@@ -33,9 +33,7 @@  void test01()
   VERIFY( (test_category<is_unsigned, char>(false)) );
   VERIFY( (test_category<is_unsigned, signed char>(false)) );
   VERIFY( (test_category<is_unsigned, unsigned char>(true)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_unsigned, wchar_t>(false)) );
-#endif
   VERIFY( (test_category<is_unsigned, short>(false)) );
   VERIFY( (test_category<is_unsigned, unsigned short>(true)) );
   VERIFY( (test_category<is_unsigned, int>(false)) );
diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc
index b89e9d27f7d..291c5b85fb3 100644
--- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc
+++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc
@@ -33,9 +33,7 @@  void test01()
   VERIFY( (test_category<is_void, char>(false)) );
   VERIFY( (test_category<is_void, signed char>(false)) );
   VERIFY( (test_category<is_void, unsigned char>(false)) );
-#ifdef _GLIBCXX_USE_WCHAR_T
   VERIFY( (test_category<is_void, wchar_t>(false)) );
-#endif
   VERIFY( (test_category<is_void, short>(false)) );
   VERIFY( (test_category<is_void, unsigned short>(false)) );
   VERIFY( (test_category<is_void, int>(false)) );
diff --git a/libstdc++-v3/testsuite/tr1/6_containers/hash/24799.cc b/libstdc++-v3/testsuite/tr1/6_containers/hash/24799.cc
index 6b7c8f83955..36ed00989fa 100644
--- a/libstdc++-v3/testsuite/tr1/6_containers/hash/24799.cc
+++ b/libstdc++-v3/testsuite/tr1/6_containers/hash/24799.cc
@@ -58,10 +58,8 @@  void test01()
   do_test<double>();
   do_test<long double>();
 
-#ifdef _GLIBCXX_USE_WCHAR_T
   do_test<wchar_t>();
   do_test<std::wstring>();
-#endif
 }
 
 int main()