46 multiset<_Key, _Compare, _Allocator>, _Allocator,
47 __gnu_debug::_Safe_node_sequence>,
48 public _GLIBCXX_STD_C::multiset<_Key, _Compare, _Allocator>
50 typedef _GLIBCXX_STD_C::multiset<_Key, _Compare, _Allocator>
_Base;
61 typedef _Key value_type;
62 typedef _Compare key_compare;
63 typedef _Compare value_compare;
65 typedef typename _Base::reference reference;
66 typedef typename _Base::const_reference const_reference;
73 typedef typename _Base::size_type size_type;
74 typedef typename _Base::difference_type difference_type;
75 typedef typename _Base::pointer pointer;
76 typedef typename _Base::const_pointer const_pointer;
82#if __cplusplus < 201103L
95 const _Compare& __comp = _Compare(),
104 :
_Base(__m, __a) { }
107 :
_Safe(std::move(__m._M_safe()), __a),
108 _Base(std::move(__m._M_base()), __a) { }
114 template<
typename _InputIterator>
117 :
_Base(__gnu_debug::__base(__gnu_debug::__check_valid_range(__first,
119 __gnu_debug::__base(__last), __a) { }
124 explicit multiset(
const _Compare& __comp,
126 :
_Base(__comp, __a) { }
128 template<
typename _InputIterator>
130 const _Compare& __comp = _Compare(),
132 :
_Base(__gnu_debug::__base(__gnu_debug::__check_valid_range(__first,
134 __gnu_debug::__base(__last),
140#if __cplusplus < 201103L
144 this->_M_safe() = __x;
150 operator=(
const multiset&) =
default;
159 this->_M_invalidate_all();
164 using _Base::get_allocator;
169 {
return iterator(_Base::begin(),
this); }
177 {
return iterator(_Base::end(),
this); }
199#if __cplusplus >= 201103L
201 cbegin()
const noexcept
205 cend()
const noexcept
209 crbegin()
const noexcept
213 crend()
const noexcept
220 using _Base::max_size;
223#if __cplusplus >= 201103L
224 template<
typename...
_Args>
232 template<
typename...
_Args>
244 insert(
const value_type& __x)
245 {
return iterator(_Base::insert(__x),
this); }
247#if __cplusplus >= 201103L
249 insert(value_type&& __x)
250 {
return iterator(_Base::insert(std::move(__x)),
this); }
260#if __cplusplus >= 201103L
270 template<
typename _InputIterator>
275 __glibcxx_check_valid_range2(__first, __last,
__dist);
277 if (
__dist.second >= __gnu_debug::__dp_sign)
278 _Base::insert(__gnu_debug::__unsafe(__first),
279 __gnu_debug::__unsafe(__last));
281 _Base::insert(__first, __last);
284#if __cplusplus >= 201103L
287 { _Base::insert(
__l); }
290#if __cplusplus >= 201103L
312 _Base::equal_range(__x);
313 size_type __count = 0;
324#if __cplusplus >= 201103L
334 _GLIBCXX_DEBUG_VERIFY(
__victim != _Base::end(),
335 _M_message(__gnu_debug::__msg_valid_range)
336 ._M_iterator(__first,
"first")
337 ._M_iterator(__last,
"last"));
340 return iterator(_Base::erase(__first.base(), __last.
base()),
this);
352 _GLIBCXX_DEBUG_VERIFY(
__victim != _Base::end(),
353 _M_message(__gnu_debug::__msg_valid_range)
354 ._M_iterator(__first,
"first")
355 ._M_iterator(__last,
"last"));
358 _Base::erase(__first.base(), __last.
base());
373 this->_M_invalidate_all();
378 using _Base::key_comp;
379 using _Base::value_comp;
384 {
return iterator(_Base::find(__x),
this); }
392#if __cplusplus > 201103L
393 template<
typename _Kt,
395 typename __has_is_transparent<_Compare, _Kt>::type>
398 {
return { _Base::find(__x),
this }; }
400 template<
typename _Kt,
402 typename __has_is_transparent<_Compare, _Kt>::type>
404 find(
const _Kt& __x)
const
405 {
return { _Base::find(__x),
this }; }
412 {
return iterator(_Base::lower_bound(__x),
this); }
417 lower_bound(
const key_type& __x)
const
420#if __cplusplus > 201103L
421 template<
typename _Kt,
423 typename __has_is_transparent<_Compare, _Kt>::type>
425 lower_bound(
const _Kt& __x)
426 {
return { _Base::lower_bound(__x),
this }; }
428 template<
typename _Kt,
430 typename __has_is_transparent<_Compare, _Kt>::type>
432 lower_bound(
const _Kt& __x)
const
433 {
return { _Base::lower_bound(__x),
this }; }
438 {
return iterator(_Base::upper_bound(__x),
this); }
443 upper_bound(
const key_type& __x)
const
446#if __cplusplus > 201103L
447 template<
typename _Kt,
449 typename __has_is_transparent<_Compare, _Kt>::type>
451 upper_bound(
const _Kt& __x)
452 {
return { _Base::upper_bound(__x),
this }; }
454 template<
typename _Kt,
456 typename __has_is_transparent<_Compare, _Kt>::type>
458 upper_bound(
const _Kt& __x)
const
459 {
return { _Base::upper_bound(__x),
this }; }
466 _Base::equal_range(__x);
474 equal_range(
const key_type& __x)
const
477 _Base::equal_range(__x);
482#if __cplusplus > 201103L
483 template<
typename _Kt,
485 typename __has_is_transparent<_Compare, _Kt>::type>
487 equal_range(
const _Kt& __x)
489 auto __res = _Base::equal_range(__x);
490 return { {
__res.first,
this }, {
__res.second,
this } };
493 template<
typename _Kt,
495 typename __has_is_transparent<_Compare, _Kt>::type>
497 equal_range(
const _Kt& __x)
const
499 auto __res = _Base::equal_range(__x);
500 return { {
__res.first,
this }, {
__res.second,
this } };