48#if __cplusplus >= 201103L
52#define __cpp_lib_incomplete_container_elements 201505
54namespace std _GLIBCXX_VISIBILITY(default)
56_GLIBCXX_BEGIN_NAMESPACE_VERSION
75 typedef void value_type;
76 typedef size_t size_type;
77 typedef ptrdiff_t difference_type;
79#if __cplusplus <= 201703L
81 typedef void* pointer;
82 typedef const void* const_pointer;
84 template<
typename _Tp1>
89#if __cplusplus >= 201103L
95 _GLIBCXX20_DEPRECATED_SUGGEST(
"std::allocator_traits::is_always_equal")
98#if __cplusplus >= 202002L
104 template<
typename _Up>
123 template<
typename _Tp>
127 typedef _Tp value_type;
128 typedef size_t size_type;
129 typedef ptrdiff_t difference_type;
131#if __cplusplus <= 201703L
133 typedef _Tp* pointer;
134 typedef const _Tp* const_pointer;
135 typedef _Tp& reference;
136 typedef const _Tp& const_reference;
138 template<
typename _Tp1>
143#if __cplusplus >= 201103L
149 _GLIBCXX20_DEPRECATED_SUGGEST(
"std::allocator_traits::is_always_equal")
162#if __cplusplus >= 201103L
167 template<
typename _Tp1>
171#if __cpp_constexpr_dynamic_alloc
176#if __cplusplus > 201703L
177 [[nodiscard,__gnu__::__always_inline__]]
181#ifdef __cpp_lib_is_constant_evaluated
182 if (std::is_constant_evaluated())
183 return static_cast<_Tp*
>(::operator
new(__n *
sizeof(_Tp)));
188 [[__gnu__::__always_inline__]]
190 deallocate(_Tp* __p,
size_t __n)
192#ifdef __cpp_lib_is_constant_evaluated
193 if (std::is_constant_evaluated())
195 ::operator
delete(__p);
203 friend _GLIBCXX20_CONSTEXPR
bool
207#if __cpp_impl_three_way_comparison < 201907L
208 friend _GLIBCXX20_CONSTEXPR
bool
216 template<
typename _T1,
typename _T2>
217 inline _GLIBCXX20_CONSTEXPR
bool
222#if __cpp_impl_three_way_comparison < 201907L
223 template<
typename _T1,
typename _T2>
224 inline _GLIBCXX20_CONSTEXPR
bool
225 operator!=(
const allocator<_T1>&,
const allocator<_T2>&)
232 template<
typename _Tp>
233 class allocator<const _Tp>
236 typedef _Tp value_type;
237 template<
typename _Up> allocator(
const allocator<_Up>&) { }
240 template<
typename _Tp>
241 class allocator<volatile _Tp>
244 typedef _Tp value_type;
245 template<
typename _Up> allocator(
const allocator<_Up>&) { }
248 template<
typename _Tp>
249 class allocator<const volatile _Tp>
252 typedef _Tp value_type;
253 template<
typename _Up> allocator(
const allocator<_Up>&) { }
260#if _GLIBCXX_EXTERN_TEMPLATE
261 extern template class allocator<char>;
262 extern template class allocator<wchar_t>;
266#undef __allocator_base
269 template<
typename _Alloc,
bool = __is_empty(_Alloc)>
271 {
static void _S_do_it(_Alloc&, _Alloc&) _GLIBCXX_NOEXCEPT { } };
273 template<
typename _Alloc>
274 struct __alloc_swap<_Alloc, false>
277 _S_do_it(_Alloc& __one, _Alloc& __two) _GLIBCXX_NOEXCEPT
286 template<
typename _Alloc,
bool = __is_empty(_Alloc)>
290 _S_do_it(
const _Alloc&,
const _Alloc&)
294 template<
typename _Alloc>
295 struct __alloc_neq<_Alloc, false>
298 _S_do_it(
const _Alloc& __one,
const _Alloc& __two)
299 {
return __one != __two; }
302#if __cplusplus >= 201103L
303 template<
typename _Tp,
bool
304 = __or_<is_copy_constructible<typename _Tp::value_type>,
305 is_nothrow_move_constructible<typename _Tp::value_type>>::value>
306 struct __shrink_to_fit_aux
307 {
static bool _S_do_it(_Tp&)
noexcept {
return false; } };
309 template<
typename _Tp>
310 struct __shrink_to_fit_aux<_Tp, true>
313 _S_do_it(_Tp& __c)
noexcept
318 _Tp(__make_move_if_noexcept_iterator(__c.begin()),
319 __make_move_if_noexcept_iterator(__c.end()),
320 __c.get_allocator()).swap(__c);
332_GLIBCXX_END_NAMESPACE_VERSION
integral_constant< bool, true > true_type
The type used as a compile-time boolean with true value.
void swap(any &__x, any &__y) noexcept
Exchange the states of two any objects.
ISO C++ entities toplevel namespace is std.
The standard allocator, as per C++03 [20.4.1].
An allocator that uses global new, as per C++03 [20.4.1].