44 #define _ALLOCATOR_H 1
48 #if __cplusplus >= 201103L
52 namespace std _GLIBCXX_VISIBILITY(default)
54 _GLIBCXX_BEGIN_NAMESPACE_VERSION
66 typedef size_t size_type;
67 typedef ptrdiff_t difference_type;
68 typedef void* pointer;
69 typedef const void* const_pointer;
70 typedef void value_type;
72 template<
typename _Tp1>
76 #if __cplusplus >= 201103L
91 template<
typename _Tp>
95 typedef size_t size_type;
96 typedef ptrdiff_t difference_type;
98 typedef const _Tp* const_pointer;
99 typedef _Tp& reference;
100 typedef const _Tp& const_reference;
101 typedef _Tp value_type;
103 template<
typename _Tp1>
107 #if __cplusplus >= 201103L
118 template<
typename _Tp1>
126 template<
typename _T1,
typename _T2>
131 template<
typename _Tp>
133 operator==(
const allocator<_Tp>&,
const allocator<_Tp>&)
136 template<
typename _T1,
typename _T2>
138 operator!=(
const allocator<_T1>&,
const allocator<_T2>&)
141 template<
typename _Tp>
143 operator!=(
const allocator<_Tp>&,
const allocator<_Tp>&)
150 #if _GLIBCXX_EXTERN_TEMPLATE
151 extern template class allocator<char>;
152 extern template class allocator<wchar_t>;
156 #undef __allocator_base
159 template<
typename _Alloc,
bool = __is_empty(_Alloc)>
161 {
static void _S_do_it(_Alloc&, _Alloc&) _GLIBCXX_NOEXCEPT { } };
163 template<
typename _Alloc>
164 struct __alloc_swap<_Alloc, false>
167 _S_do_it(_Alloc& __one, _Alloc& __two) _GLIBCXX_NOEXCEPT
176 template<
typename _Alloc,
bool = __is_empty(_Alloc)>
180 _S_do_it(
const _Alloc&,
const _Alloc&)
184 template<
typename _Alloc>
185 struct __alloc_neq<_Alloc, false>
188 _S_do_it(
const _Alloc& __one,
const _Alloc& __two)
189 {
return __one != __two; }
192 #if __cplusplus >= 201103L
193 template<
typename _Tp,
bool
194 = __or_<is_copy_constructible<typename _Tp::value_type>,
195 is_nothrow_move_constructible<typename _Tp::value_type>>::value>
196 struct __shrink_to_fit_aux
197 {
static bool _S_do_it(_Tp&) noexcept {
return false; } };
199 template<
typename _Tp>
200 struct __shrink_to_fit_aux<_Tp, true>
203 _S_do_it(_Tp& __c) noexcept
207 _Tp(__make_move_if_noexcept_iterator(__c.begin()),
208 __make_move_if_noexcept_iterator(__c.end()),
209 __c.get_allocator()).
swap(__c);
218 _GLIBCXX_END_NAMESPACE_VERSION
An allocator that uses global new, as per [20.4].This is precisely the allocator defined in the C++ S...
The standard allocator, as per [20.4].
void swap(function< _Res(_Args...)> &__x, function< _Res(_Args...)> &__y)
Swap the targets of two polymorphic function object wrappers.