1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 // P2251 was voted into C++23, but is supported even in C++17 mode by all vendors.
10 
11 // <string_view>
12 
13 #include <string_view>
14 #include <type_traits>
15 
16 #include "test_macros.h"
17 
18 static_assert(std::is_trivially_copyable<std::basic_string_view<char> >::value, "");
19 #ifndef TEST_HAS_NO_WIDE_CHARACTERS
20 static_assert(std::is_trivially_copyable<std::basic_string_view<wchar_t> >::value, "");
21 #endif
22 #ifndef _LIBCPP_HAS_NO_CHAR8_T
23 static_assert(std::is_trivially_copyable<std::basic_string_view<char8_t> >::value, "");
24 #endif
25 static_assert(std::is_trivially_copyable<std::basic_string_view<char16_t> >::value, "");
26 static_assert(std::is_trivially_copyable<std::basic_string_view<char32_t> >::value, "");
27