56#define _GLIBCXX_DEQUE 1
58#pragma GCC system_header
71#define __glibcxx_want_allocator_traits_is_always_equal
72#define __glibcxx_want_erase_if
73#define __glibcxx_want_nonmember_container_access
80#if __cplusplus >= 201703L
82namespace std _GLIBCXX_VISIBILITY(default)
84_GLIBCXX_BEGIN_NAMESPACE_VERSION
87 template<
typename _Tp>
88 using deque = std::deque<_Tp, polymorphic_allocator<_Tp>>;
90_GLIBCXX_END_NAMESPACE_VERSION
94#ifdef __cpp_lib_erase_if
95namespace std _GLIBCXX_VISIBILITY(default)
97_GLIBCXX_BEGIN_NAMESPACE_VERSION
99 template<
typename _Tp,
typename _Alloc,
typename _Predicate>
100 inline typename deque<_Tp, _Alloc>::size_type
103 using namespace __gnu_cxx;
104 _GLIBCXX_STD_C::deque<_Tp, _Alloc>& __ucont = __cont;
105 const auto __osz = __cont.size();
106 const auto __end = __ucont.end();
107 auto __removed = std::__remove_if(__ucont.begin(), __end,
108 __ops::__pred_iter(
std::ref(__pred)));
109 if (__removed != __end)
111 __cont.erase(__niter_wrap(__cont.begin(), __removed),
113 return __osz - __cont.size();
119 template<
typename _Tp,
typename _Alloc,
typename _Up>
120 inline typename deque<_Tp, _Alloc>::size_type
123 using namespace __gnu_cxx;
124 _GLIBCXX_STD_C::deque<_Tp, _Alloc>& __ucont = __cont;
125 const auto __osz = __cont.size();
126 const auto __end = __ucont.end();
127 auto __removed = std::__remove_if(__ucont.begin(), __end,
128 __ops::__iter_equals_val(__value));
129 if (__removed != __end)
131 __cont.erase(__niter_wrap(__cont.begin(), __removed),
133 return __osz - __cont.size();
138_GLIBCXX_END_NAMESPACE_VERSION
ISO C++ entities toplevel namespace is std.
constexpr reference_wrapper< _Tp > ref(_Tp &__t) noexcept
Denotes a reference should be taken to a variable.
A standard container using fixed-size memory allocation and constant-time manipulation of elements at...