mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-27 20:06:06 +00:00
Cleanup _LIBCPP_HAS_NO_<c++11-feature> for std::set and std::multiset
llvm-svn: 300595
This commit is contained in:
parent
a0320b97fa
commit
922940b627
@ -486,12 +486,12 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
set(set&& __s)
|
||||
_NOEXCEPT_(is_nothrow_move_constructible<__base>::value)
|
||||
: __tree_(_VSTD::move(__s.__tree_)) {}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
explicit set(const allocator_type& __a)
|
||||
@ -504,11 +504,9 @@ public:
|
||||
insert(__s.begin(), __s.end());
|
||||
}
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
set(set&& __s, const allocator_type& __a);
|
||||
#endif
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
set(initializer_list<value_type> __il, const value_compare& __comp = value_compare())
|
||||
: __tree_(__comp)
|
||||
@ -536,9 +534,7 @@ public:
|
||||
__tree_.__assign_unique(__il.begin(), __il.end());
|
||||
return *this;
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
set& operator=(set&& __s)
|
||||
_NOEXCEPT_(is_nothrow_move_assignable<__base>::value)
|
||||
@ -546,7 +542,7 @@ public:
|
||||
__tree_ = _VSTD::move(__s.__tree_);
|
||||
return *this;
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator begin() _NOEXCEPT {return __tree_.begin();}
|
||||
@ -587,7 +583,7 @@ public:
|
||||
size_type max_size() const _NOEXCEPT {return __tree_.max_size();}
|
||||
|
||||
// modifiers:
|
||||
#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS)
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
template <class... _Args>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
pair<iterator, bool> emplace(_Args&&... __args)
|
||||
@ -596,23 +592,15 @@ public:
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator emplace_hint(const_iterator __p, _Args&&... __args)
|
||||
{return __tree_.__emplace_hint_unique(__p, _VSTD::forward<_Args>(__args)...);}
|
||||
#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS)
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
pair<iterator,bool> insert(const value_type& __v)
|
||||
{return __tree_.__insert_unique(__v);}
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
pair<iterator,bool> insert(value_type&& __v)
|
||||
{return __tree_.__insert_unique(_VSTD::move(__v));}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, const value_type& __v)
|
||||
{return __tree_.__insert_unique(__p, __v);}
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, value_type&& __v)
|
||||
{return __tree_.__insert_unique(__p, _VSTD::move(__v));}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
|
||||
template <class _InputIterator>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void insert(_InputIterator __f, _InputIterator __l)
|
||||
@ -621,11 +609,19 @@ public:
|
||||
__tree_.__insert_unique(__e, *__f);
|
||||
}
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
pair<iterator,bool> insert(value_type&& __v)
|
||||
{return __tree_.__insert_unique(_VSTD::move(__v));}
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, value_type&& __v)
|
||||
{return __tree_.__insert_unique(__p, _VSTD::move(__v));}
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void insert(initializer_list<value_type> __il)
|
||||
{insert(__il.begin(), __il.end());}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator erase(const_iterator __p) {return __tree_.erase(__p);}
|
||||
@ -727,7 +723,7 @@ public:
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
|
||||
template <class _Key, class _Compare, class _Allocator>
|
||||
set<_Key, _Compare, _Allocator>::set(set&& __s, const allocator_type& __a)
|
||||
@ -741,7 +737,7 @@ set<_Key, _Compare, _Allocator>::set(set&& __s, const allocator_type& __a)
|
||||
}
|
||||
}
|
||||
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
template <class _Key, class _Compare, class _Allocator>
|
||||
inline _LIBCPP_INLINE_VISIBILITY
|
||||
@ -901,12 +897,14 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
multiset(multiset&& __s)
|
||||
_NOEXCEPT_(is_nothrow_move_constructible<__base>::value)
|
||||
: __tree_(_VSTD::move(__s.__tree_)) {}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
|
||||
multiset(multiset&& __s, const allocator_type& __a);
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
explicit multiset(const allocator_type& __a)
|
||||
: __tree_(__a) {}
|
||||
@ -916,11 +914,8 @@ public:
|
||||
{
|
||||
insert(__s.begin(), __s.end());
|
||||
}
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
multiset(multiset&& __s, const allocator_type& __a);
|
||||
#endif
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
multiset(initializer_list<value_type> __il, const value_compare& __comp = value_compare())
|
||||
: __tree_(__comp)
|
||||
@ -948,9 +943,7 @@ public:
|
||||
__tree_.__assign_multi(__il.begin(), __il.end());
|
||||
return *this;
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
multiset& operator=(multiset&& __s)
|
||||
_NOEXCEPT_(is_nothrow_move_assignable<__base>::value)
|
||||
@ -958,7 +951,7 @@ public:
|
||||
__tree_ = _VSTD::move(__s.__tree_);
|
||||
return *this;
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator begin() _NOEXCEPT {return __tree_.begin();}
|
||||
@ -999,7 +992,7 @@ public:
|
||||
size_type max_size() const _NOEXCEPT {return __tree_.max_size();}
|
||||
|
||||
// modifiers:
|
||||
#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS)
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
template <class... _Args>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator emplace(_Args&&... __args)
|
||||
@ -1008,23 +1001,15 @@ public:
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator emplace_hint(const_iterator __p, _Args&&... __args)
|
||||
{return __tree_.__emplace_hint_multi(__p, _VSTD::forward<_Args>(__args)...);}
|
||||
#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS)
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const value_type& __v)
|
||||
{return __tree_.__insert_multi(__v);}
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(value_type&& __v)
|
||||
{return __tree_.__insert_multi(_VSTD::move(__v));}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, const value_type& __v)
|
||||
{return __tree_.__insert_multi(__p, __v);}
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, value_type&& __v)
|
||||
{return __tree_.__insert_multi(__p, _VSTD::move(__v));}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
|
||||
template <class _InputIterator>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void insert(_InputIterator __f, _InputIterator __l)
|
||||
@ -1033,11 +1018,19 @@ public:
|
||||
__tree_.__insert_multi(__e, *__f);
|
||||
}
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(value_type&& __v)
|
||||
{return __tree_.__insert_multi(_VSTD::move(__v));}
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator insert(const_iterator __p, value_type&& __v)
|
||||
{return __tree_.__insert_multi(__p, _VSTD::move(__v));}
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void insert(initializer_list<value_type> __il)
|
||||
{insert(__il.begin(), __il.end());}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
iterator erase(const_iterator __p) {return __tree_.erase(__p);}
|
||||
@ -1140,7 +1133,7 @@ public:
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#ifndef _LIBCPP_CXX03_LANG
|
||||
|
||||
template <class _Key, class _Compare, class _Allocator>
|
||||
multiset<_Key, _Compare, _Allocator>::multiset(multiset&& __s, const allocator_type& __a)
|
||||
@ -1154,7 +1147,7 @@ multiset<_Key, _Compare, _Allocator>::multiset(multiset&& __s, const allocator_t
|
||||
}
|
||||
}
|
||||
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#endif // _LIBCPP_CXX03_LANG
|
||||
|
||||
template <class _Key, class _Compare, class _Allocator>
|
||||
inline _LIBCPP_INLINE_VISIBILITY
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::multiset<DefaultOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -68,7 +69,6 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> M;
|
||||
typedef M::iterator R;
|
||||
@ -78,6 +78,4 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::multiset<DefaultOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -68,7 +69,6 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> M;
|
||||
typedef M::iterator R;
|
||||
@ -78,6 +78,4 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::multiset<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -39,8 +40,6 @@ int main()
|
||||
assert(*++i == V(8));
|
||||
assert(*++i == V(10));
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -58,5 +57,4 @@ int main()
|
||||
assert(*++i == V(8));
|
||||
assert(*++i == V(10));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::multiset<MoveOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -46,8 +47,6 @@ int main()
|
||||
assert(m.size() == 4);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<MoveOnly, std::less<MoveOnly>, min_allocator<MoveOnly>> M;
|
||||
typedef M::iterator R;
|
||||
@ -72,5 +71,4 @@ int main()
|
||||
assert(m.size() == 4);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::multiset<MoveOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -46,8 +47,6 @@ int main()
|
||||
assert(m.size() == 4);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<MoveOnly, std::less<MoveOnly>, min_allocator<MoveOnly>> M;
|
||||
typedef M::iterator R;
|
||||
@ -72,5 +71,4 @@ int main()
|
||||
assert(m.size() == 4);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -20,7 +22,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::multiset<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -36,8 +37,6 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -53,5 +52,4 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::multiset<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -36,8 +37,6 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -52,7 +51,6 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#if TEST_STD_VER > 11
|
||||
{
|
||||
typedef std::multiset<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -69,6 +67,4 @@ int main()
|
||||
assert(*++i == V(6));
|
||||
assert(m.get_allocator() == a);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -19,7 +21,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
typedef test_compare<std::less<int> > Cmp;
|
||||
typedef std::multiset<int, Cmp> C;
|
||||
typedef C::value_type V;
|
||||
@ -34,5 +35,4 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
assert(m.key_comp() == Cmp(10));
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -20,7 +22,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
typedef test_compare<std::less<int> > Cmp;
|
||||
typedef test_allocator<int> A;
|
||||
typedef std::multiset<int, Cmp, A> C;
|
||||
@ -37,5 +38,4 @@ int main()
|
||||
assert(*++i == V(6));
|
||||
assert(m.key_comp() == Cmp(10));
|
||||
assert(m.get_allocator() == A(4));
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -22,7 +24,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef int V;
|
||||
typedef test_compare<std::less<int> > C;
|
||||
@ -76,8 +77,6 @@ int main()
|
||||
assert(mo.size() == 0);
|
||||
assert(distance(mo.begin(), mo.end()) == 0);
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef int V;
|
||||
V ar[] =
|
||||
@ -115,5 +114,4 @@ int main()
|
||||
assert(mo.size() == 0);
|
||||
assert(distance(mo.begin(), mo.end()) == 0);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -183,5 +184,4 @@ int main()
|
||||
}
|
||||
assert(Counter_base::gConstructed == 0);
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class multiset
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -141,8 +142,6 @@ int main()
|
||||
assert(m3.key_comp() == C(5));
|
||||
assert(m1.empty());
|
||||
}
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -182,5 +181,4 @@ int main()
|
||||
assert(m3.key_comp() == C(5));
|
||||
assert(m1.empty());
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::set<DefaultOnly> M;
|
||||
typedef std::pair<M::iterator, bool> R;
|
||||
@ -74,7 +75,6 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r.first == 2);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<int, std::less<int>, min_allocator<int>> M;
|
||||
typedef std::pair<M::iterator, bool> R;
|
||||
@ -85,6 +85,4 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r.first == 2);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::set<DefaultOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -68,7 +69,6 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<int, std::less<int>, min_allocator<int>> M;
|
||||
typedef M::iterator R;
|
||||
@ -78,6 +78,4 @@ int main()
|
||||
assert(m.size() == 1);
|
||||
assert(*r == 2);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::set<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -39,7 +40,6 @@ int main()
|
||||
assert(*++i == V(8));
|
||||
assert(*++i == V(10));
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -57,6 +57,4 @@ int main()
|
||||
assert(*++i == V(8));
|
||||
assert(*++i == V(10));
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::set<MoveOnly> M;
|
||||
typedef M::iterator R;
|
||||
@ -46,7 +47,6 @@ int main()
|
||||
assert(m.size() == 3);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<MoveOnly, std::less<MoveOnly>, min_allocator<MoveOnly>> M;
|
||||
typedef M::iterator R;
|
||||
@ -71,6 +71,4 @@ int main()
|
||||
assert(m.size() == 3);
|
||||
assert(*r == 3);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -21,7 +23,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef std::set<MoveOnly> M;
|
||||
typedef std::pair<M::iterator, bool> R;
|
||||
@ -50,7 +51,6 @@ int main()
|
||||
assert(m.size() == 3);
|
||||
assert(*r.first == 3);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<MoveOnly, std::less<MoveOnly>, min_allocator<MoveOnly>> M;
|
||||
typedef std::pair<M::iterator, bool> R;
|
||||
@ -79,6 +79,4 @@ int main()
|
||||
assert(m.size() == 3);
|
||||
assert(*r.first == 3);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -20,7 +22,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::set<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -36,7 +37,6 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -52,6 +52,4 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -20,7 +22,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef std::set<int> C;
|
||||
typedef C::value_type V;
|
||||
@ -35,7 +36,6 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::set<int, std::less<int>, min_allocator<int>> C;
|
||||
typedef C::value_type V;
|
||||
@ -50,6 +50,4 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -19,7 +21,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
typedef test_compare<std::less<int> > Cmp;
|
||||
typedef std::set<int, Cmp> C;
|
||||
typedef C::value_type V;
|
||||
@ -34,5 +35,4 @@ int main()
|
||||
assert(*++i == V(5));
|
||||
assert(*++i == V(6));
|
||||
assert(m.key_comp() == Cmp(10));
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -22,7 +24,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
{
|
||||
typedef test_compare<std::less<int> > Cmp;
|
||||
typedef test_allocator<int> A;
|
||||
@ -41,7 +42,6 @@ int main()
|
||||
assert(m.key_comp() == Cmp(10));
|
||||
assert(m.get_allocator() == A(4));
|
||||
}
|
||||
#if TEST_STD_VER > 11
|
||||
{
|
||||
typedef test_compare<std::less<int> > Cmp;
|
||||
typedef test_allocator<int> A;
|
||||
@ -59,6 +59,4 @@ int main()
|
||||
assert(*++i == V(6));
|
||||
assert(m.get_allocator() == A(4));
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -22,7 +24,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef int V;
|
||||
typedef test_compare<std::less<int> > C;
|
||||
@ -70,7 +71,6 @@ int main()
|
||||
assert(mo.size() == 0);
|
||||
assert(distance(mo.begin(), mo.end()) == 0);
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef int V;
|
||||
V ar[] =
|
||||
@ -102,6 +102,4 @@ int main()
|
||||
assert(mo.size() == 0);
|
||||
assert(distance(mo.begin(), mo.end()) == 0);
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -184,5 +185,4 @@ int main()
|
||||
assert(Counter_base::gConstructed == 0);
|
||||
}
|
||||
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
//
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// UNSUPPORTED: c++98, c++03
|
||||
|
||||
// <set>
|
||||
|
||||
// class set
|
||||
@ -23,7 +25,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -141,7 +142,6 @@ int main()
|
||||
assert(m3.key_comp() == C(5));
|
||||
assert(m1.empty());
|
||||
}
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef MoveOnly V;
|
||||
typedef test_compare<std::less<MoveOnly> > C;
|
||||
@ -181,6 +181,4 @@ int main()
|
||||
assert(m3.key_comp() == C(5));
|
||||
assert(m1.empty());
|
||||
}
|
||||
#endif
|
||||
#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user