55#ifndef _GLIBCXX_UTILITY
56#define _GLIBCXX_UTILITY 1
59#pragma GCC system_header
73#if __cplusplus >= 201103L
80#if __cplusplus >= 202002L
84#if __cplusplus > 202302L
88#define __glibcxx_want_addressof_constexpr
89#define __glibcxx_want_as_const
90#define __glibcxx_want_constant_wrapper
91#define __glibcxx_want_constexpr_algorithms
92#define __glibcxx_want_constexpr_utility
93#define __glibcxx_want_exchange_function
94#define __glibcxx_want_forward_like
95#define __glibcxx_want_integer_comparison_functions
96#define __glibcxx_want_integer_sequence
97#define __glibcxx_want_ranges_zip
98#define __glibcxx_want_to_underlying
99#define __glibcxx_want_tuple_element_t
100#define __glibcxx_want_tuples_by_type
101#define __glibcxx_want_unreachable
102#define __glibcxx_want_observable_checkpoint
103#define __glibcxx_want_tuple_like
104#define __glibcxx_want_constrained_equality
107namespace std _GLIBCXX_VISIBILITY(default)
109_GLIBCXX_BEGIN_NAMESPACE_VERSION
111#ifdef __cpp_lib_exchange_function
113 template <typename _Tp, typename _Up = _Tp>
116 exchange(_Tp& __obj, _Up&& __new_val)
117 noexcept(__and_<is_nothrow_move_constructible<_Tp>,
122#ifdef __cpp_lib_as_const
123 template<
typename _Tp>
125 constexpr add_const_t<_Tp>&
126 as_const(_Tp& __t)
noexcept
129 template<
typename _Tp>
130 void as_const(
const _Tp&&) =
delete;
133#ifdef __cpp_lib_to_underlying
135 template<typename _Tp>
136 [[nodiscard, __gnu__::__always_inline__]]
138 to_underlying(_Tp __value)
noexcept
142#ifdef __cpp_lib_unreachable
155 [[noreturn,__gnu__::__always_inline__]]
160 std::__glibcxx_assert_fail(
nullptr, 0,
"std::unreachable()",
nullptr);
161#elif defined _GLIBCXX_ASSERTIONS
164 __builtin_unreachable();
170#ifdef __cpp_lib_observable_checkpoint
179 [[__gnu__::__always_inline__]]
181 observable_checkpoint() noexcept
183 return __builtin_observable_checkpoint();
187_GLIBCXX_END_NAMESPACE_VERSION
typename underlying_type< _Tp >::type underlying_type_t
Alias template for underlying_type.
constexpr _Tp && forward(typename std::remove_reference< _Tp >::type &__t) noexcept
Forward an lvalue.
ISO C++ entities toplevel namespace is std.