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 // UNSUPPORTED: c++03, c++11, c++14, c++17 10 // UNSUPPORTED: libcpp-no-concepts 11 // UNSUPPORTED: gcc-10 12 13 // struct default_sentinel_t; 14 // inline constexpr default_sentinel_t default_sentinel; 15 16 #include <iterator> 17 18 #include <concepts> 19 #include <type_traits> 20 21 #include "test_macros.h" 22 23 int main(int, char**) { 24 static_assert(std::is_empty_v<std::default_sentinel_t>); 25 static_assert(std::semiregular<std::default_sentinel_t>); 26 27 static_assert(std::same_as<decltype(std::default_sentinel), const std::default_sentinel_t>); 28 29 std::default_sentinel_t s1; 30 auto s2 = std::default_sentinel_t{}; 31 s2 = s1; 32 33 return 0; 34 } 35