Commit 62bb0c97 by Phil Edwards

boost_concept_check.h: Uglify, fork from Boost.

2001-04-13  Phil Edwards  <pme@sources.redhat.com>

	* include/bits/boost_concept_check.h:  Uglify, fork from Boost.
	* include/bits/concept_check.h:  Uglify.
	* include/bits/stl_algo.h:  Likewise.
	* include/bits/stl_algobase.h:  Likewise.
	* include/bits/stl_deque.h:  Likewise.
	* include/bits/stl_heap.h:  Likewise.
	* include/bits/stl_iterator_base_funcs.h:  Likewise.
	* include/bits/stl_list.h:  Likewise.
	* include/bits/stl_map.h:  Likewise.
	* include/bits/stl_multimap.h:  Likewise.
	* include/bits/stl_multiset.h:  Likewise.
	* include/bits/stl_numeric.h:  Likewise.
	* include/bits/stl_queue.h:  Likewise.
	* include/bits/stl_set.h:  Likewise.
	* include/bits/stl_stack.h:  Likewise.
	* include/bits/stl_vector.h:  Likewise.
	* include/ext/hash_map:  Likewise.
	* include/ext/hash_set:  Likewise.
	* include/ext/slist:  Likewise.

From-SVN: r41333
parent 1f212504
2001-04-13 Phil Edwards <pme@sources.redhat.com>
* include/bits/boost_concept_check.h: Uglify, fork from Boost.
* include/bits/concept_check.h: Uglify.
* include/bits/stl_algo.h: Likewise.
* include/bits/stl_algobase.h: Likewise.
* include/bits/stl_deque.h: Likewise.
* include/bits/stl_heap.h: Likewise.
* include/bits/stl_iterator_base_funcs.h: Likewise.
* include/bits/stl_list.h: Likewise.
* include/bits/stl_map.h: Likewise.
* include/bits/stl_multimap.h: Likewise.
* include/bits/stl_multiset.h: Likewise.
* include/bits/stl_numeric.h: Likewise.
* include/bits/stl_queue.h: Likewise.
* include/bits/stl_set.h: Likewise.
* include/bits/stl_stack.h: Likewise.
* include/bits/stl_vector.h: Likewise.
* include/ext/hash_map: Likewise.
* include/ext/hash_set: Likewise.
* include/ext/slist: Likewise.
2001-04-13 Gabriel Dos Reis <gdr@codesourcery.com>
* testsuite/23_containers/set_operators.cc: Just try to compile.
......
......@@ -55,11 +55,11 @@
#if defined(_GLIBCPP_NO_CONCEPT_CHECKS) || defined(_STL_NO_CONCEPT_CHECKS) \
|| defined(NDEBUG)
#define glibcpp_function_requires(...)
#define glibcpp_class_requires(a,b)
#define glibcpp_class_requires2(a,b,c)
#define glibcpp_class_requires3(a,b,c,d)
#define glibcpp_class_requires4(a,b,c,d,e)
#define __glibcpp_function_requires(...)
#define __glibcpp_class_requires(_a,_b)
#define __glibcpp_class_requires2(_a,_b,_c)
#define __glibcpp_class_requires3(_a,_b,_c,_d)
#define __glibcpp_class_requires4(_a,_b,_c,_d,_e)
#else // the checks are on
......@@ -74,18 +74,18 @@
// BinaryPredicateConcept. The preprocessor tries to split things up on
// the commas in the template argument list. We can't use an inner pair of
// parenthesis to hide the commas, because "boost::(Temp<Foo,Bar>)" isn't
// a valid instantiation pattern.
#define glibcpp_function_requires(...) \
boost::function_requires< boost::__VA_ARGS__ >()
#define glibcpp_class_requires(a,C) \
BOOST_CLASS_REQUIRES(a, boost, C)
#define glibcpp_class_requires2(a,b,C) \
BOOST_CLASS_REQUIRES2(a, b, boost, C)
#define glibcpp_class_requires3(a,b,c,C) \
BOOST_CLASS_REQUIRES3(a, b, c, boost, C)
#define glibcpp_class_requires4(a,b,c,d,C) \
BOOST_CLASS_REQUIRES4(a, b, c, d, boost, C)
// a valid instantiation pattern. Thus, we steal a feature from C99.
#define __glibcpp_function_requires(...) \
__gnu_cxx::__function_requires< __gnu_cxx::__VA_ARGS__ >()
#define __glibcpp_class_requires(_a,_C) \
_GLIBCPP_CLASS_REQUIRES(_a, __gnu_cxx, _C)
#define __glibcpp_class_requires2(_a,_b,_C) \
_GLIBCPP_CLASS_REQUIRES2(_a, _b, __gnu_cxx, _C)
#define __glibcpp_class_requires3(_a,_b,_c,_C) \
_GLIBCPP_CLASS_REQUIRES3(_a, _b, _c, __gnu_cxx, _C)
#define __glibcpp_class_requires4(_a,_b,_c,_d,_C) \
_GLIBCPP_CLASS_REQUIRES4(_a, _b, _c, _d, __gnu_cxx, _C)
#endif // enable/disable
......
......@@ -68,12 +68,12 @@ template <class _ForwardIter1, class _ForwardIter2>
inline void iter_swap(_ForwardIter1 __a, _ForwardIter2 __b)
{
// concept requirements
glibcpp_function_requires(Mutable_ForwardIteratorConcept<_ForwardIter1>);
glibcpp_function_requires(Mutable_ForwardIteratorConcept<_ForwardIter2>);
glibcpp_function_requires(ConvertibleConcept<
__glibcpp_function_requires(_Mutable_ForwardIteratorConcept<_ForwardIter1>);
__glibcpp_function_requires(_Mutable_ForwardIteratorConcept<_ForwardIter2>);
__glibcpp_function_requires(_ConvertibleConcept<
typename iterator_traits<_ForwardIter1>::value_type,
typename iterator_traits<_ForwardIter2>::value_type>);
glibcpp_function_requires(ConvertibleConcept<
__glibcpp_function_requires(_ConvertibleConcept<
typename iterator_traits<_ForwardIter2>::value_type,
typename iterator_traits<_ForwardIter1>::value_type>);
......@@ -84,7 +84,7 @@ template <class _Tp>
inline void swap(_Tp& __a, _Tp& __b)
{
// concept requirements
glibcpp_function_requires(SGIAssignableConcept<_Tp>);
__glibcpp_function_requires(_SGIAssignableConcept<_Tp>);
_Tp __tmp = __a;
__a = __b;
......@@ -100,7 +100,7 @@ inline void swap(_Tp& __a, _Tp& __b)
template <class _Tp>
inline const _Tp& min(const _Tp& __a, const _Tp& __b) {
// concept requirements
glibcpp_function_requires(LessThanComparableConcept<_Tp>);
__glibcpp_function_requires(_LessThanComparableConcept<_Tp>);
//return __b < __a ? __b : __a;
if (__b < __a) return __b; return __a;
}
......@@ -108,7 +108,7 @@ inline const _Tp& min(const _Tp& __a, const _Tp& __b) {
template <class _Tp>
inline const _Tp& max(const _Tp& __a, const _Tp& __b) {
// concept requirements
glibcpp_function_requires(LessThanComparableConcept<_Tp>);
__glibcpp_function_requires(_LessThanComparableConcept<_Tp>);
//return __a < __b ? __b : __a;
if (__a < __b) return __b; return __a;
}
......@@ -244,8 +244,8 @@ inline _OutputIter copy(_InputIter __first, _InputIter __last,
_OutputIter __result)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIter,
__glibcpp_function_requires(_InputIteratorConcept<_InputIter>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIter,
typename iterator_traits<_InputIter>::value_type>);
typedef typename _Is_normal_iterator<_InputIter>::_Normal __Normal;
......@@ -362,9 +362,9 @@ template <typename _BI1, typename _BI2>
inline _BI2 copy_backward(_BI1 __first, _BI1 __last, _BI2 __result)
{
// concept requirements
glibcpp_function_requires(BidirectionalIteratorConcept<_BI1>);
glibcpp_function_requires(Mutable_BidirectionalIteratorConcept<_BI2>);
glibcpp_function_requires(ConvertibleConcept<
__glibcpp_function_requires(_BidirectionalIteratorConcept<_BI1>);
__glibcpp_function_requires(_Mutable_BidirectionalIteratorConcept<_BI2>);
__glibcpp_function_requires(_ConvertibleConcept<
typename iterator_traits<_BI1>::value_type,
typename iterator_traits<_BI2>::value_type>);
......@@ -409,8 +409,8 @@ inline pair<_InputIter, _OutputIter>
copy_n(_InputIter __first, _Size __count, _OutputIter __result)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIter,
__glibcpp_function_requires(_InputIteratorConcept<_InputIter>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIter,
typename iterator_traits<_InputIter>::value_type>);
return __copy_n(__first, __count, __result);
......@@ -424,7 +424,7 @@ template <class _ForwardIter, class _Tp>
void fill(_ForwardIter __first, _ForwardIter __last, const _Tp& __value)
{
// concept requirements
glibcpp_function_requires(Mutable_ForwardIteratorConcept<_ForwardIter>);
__glibcpp_function_requires(_Mutable_ForwardIteratorConcept<_ForwardIter>);
for ( ; __first != __last; ++__first)
*__first = __value;
......@@ -434,7 +434,7 @@ template <class _OutputIter, class _Size, class _Tp>
_OutputIter fill_n(_OutputIter __first, _Size __n, const _Tp& __value)
{
// concept requirements
glibcpp_function_requires(OutputIteratorConcept<_OutputIter,_Tp>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIter,_Tp>);
for ( ; __n > 0; --__n, ++__first)
*__first = __value;
......@@ -496,11 +496,11 @@ pair<_InputIter1, _InputIter2> mismatch(_InputIter1 __first1,
_InputIter2 __first2)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
glibcpp_function_requires(EqualityComparableConcept<
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_EqualityComparableConcept<
typename iterator_traits<_InputIter1>::value_type>);
glibcpp_function_requires(EqualityComparableConcept<
__glibcpp_function_requires(_EqualityComparableConcept<
typename iterator_traits<_InputIter2>::value_type>);
while (__first1 != __last1 && *__first1 == *__first2) {
......@@ -517,8 +517,8 @@ pair<_InputIter1, _InputIter2> mismatch(_InputIter1 __first1,
_BinaryPredicate __binary_pred)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
while (__first1 != __last1 && __binary_pred(*__first1, *__first2)) {
++__first1;
......@@ -532,11 +532,11 @@ inline bool equal(_InputIter1 __first1, _InputIter1 __last1,
_InputIter2 __first2)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
glibcpp_function_requires(EqualityComparableConcept<
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_EqualityComparableConcept<
typename iterator_traits<_InputIter1>::value_type>);
glibcpp_function_requires(EqualityComparableConcept<
__glibcpp_function_requires(_EqualityComparableConcept<
typename iterator_traits<_InputIter2>::value_type>);
for ( ; __first1 != __last1; ++__first1, ++__first2)
......@@ -550,8 +550,8 @@ inline bool equal(_InputIter1 __first1, _InputIter1 __last1,
_InputIter2 __first2, _BinaryPredicate __binary_pred)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
for ( ; __first1 != __last1; ++__first1, ++__first2)
if (!__binary_pred(*__first1, *__first2))
......@@ -568,11 +568,11 @@ bool lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
_InputIter2 __first2, _InputIter2 __last2)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_InputIter1>::value_type>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_InputIter2>::value_type>);
for ( ; __first1 != __last1 && __first2 != __last2
......@@ -591,8 +591,8 @@ bool lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
_Compare __comp)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
for ( ; __first1 != __last1 && __first2 != __last2
; ++__first1, ++__first2) {
......@@ -688,11 +688,11 @@ int lexicographical_compare_3way(_InputIter1 __first1, _InputIter1 __last1,
_InputIter2 __first2, _InputIter2 __last2)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter1>);
glibcpp_function_requires(InputIteratorConcept<_InputIter2>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_InputIteratorConcept<_InputIter1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter2>);
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_InputIter1>::value_type>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_InputIter2>::value_type>);
return __lexicographical_compare_3way(__first1, __last1, __first2, __last2);
......
......@@ -357,7 +357,7 @@ template <class _Tp, class _Alloc = allocator<_Tp> >
class deque : protected _Deque_base<_Tp, _Alloc> {
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
typedef _Deque_base<_Tp, _Alloc> _Base;
public: // Basic types
......
......@@ -63,9 +63,9 @@ inline void
push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_RandomAccessIterator>::value_type>);
__push_heap_aux(__first, __last,
......@@ -104,7 +104,7 @@ push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last,
_Compare __comp)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
__push_heap_aux(__first, __last, __comp,
......@@ -155,9 +155,9 @@ inline void pop_heap(_RandomAccessIterator __first,
_RandomAccessIterator __last)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_RandomAccessIterator>::value_type>);
__pop_heap_aux(__first, __last, __value_type(__first));
......@@ -212,7 +212,7 @@ pop_heap(_RandomAccessIterator __first,
_RandomAccessIterator __last, _Compare __comp)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
__pop_heap_aux(__first, __last, __value_type(__first), __comp);
......@@ -239,9 +239,9 @@ inline void
make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_RandomAccessIterator>::value_type>);
__make_heap(__first, __last,
......@@ -272,7 +272,7 @@ make_heap(_RandomAccessIterator __first,
_RandomAccessIterator __last, _Compare __comp)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
__make_heap(__first, __last, __comp,
......@@ -283,9 +283,9 @@ template <class _RandomAccessIterator>
void sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
glibcpp_function_requires(LessThanComparableConcept<
__glibcpp_function_requires(_LessThanComparableConcept<
typename iterator_traits<_RandomAccessIterator>::value_type>);
while (__last - __first > 1)
......@@ -298,7 +298,7 @@ sort_heap(_RandomAccessIterator __first,
_RandomAccessIterator __last, _Compare __comp)
{
// concept requirements
glibcpp_function_requires(Mutable_RandomAccessIteratorConcept<
__glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept<
_RandomAccessIterator>);
while (__last - __first > 1)
......
......@@ -51,7 +51,7 @@ inline void __distance(_InputIterator __first, _InputIterator __last,
_Distance& __n, input_iterator_tag)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
while (__first != __last) { ++__first; ++__n; }
}
......@@ -61,7 +61,7 @@ inline void __distance(_RandomAccessIterator __first,
_Distance& __n, random_access_iterator_tag)
{
// concept requirements
glibcpp_function_requires(RandomAccessIteratorConcept<_RandomAccessIterator>);
__glibcpp_function_requires(_RandomAccessIteratorConcept<_RandomAccessIterator>);
__n += __last - __first;
}
......@@ -78,7 +78,7 @@ inline typename iterator_traits<_InputIterator>::difference_type
__distance(_InputIterator __first, _InputIterator __last, input_iterator_tag)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
typename iterator_traits<_InputIterator>::difference_type __n = 0;
while (__first != __last) {
++__first; ++__n;
......@@ -92,7 +92,7 @@ __distance(_RandomAccessIterator __first, _RandomAccessIterator __last,
random_access_iterator_tag)
{
// concept requirements
glibcpp_function_requires(RandomAccessIteratorConcept<_RandomAccessIterator>);
__glibcpp_function_requires(_RandomAccessIteratorConcept<_RandomAccessIterator>);
return __last - __first;
}
......@@ -110,7 +110,7 @@ template <class _InputIter, class _Distance>
inline void __advance(_InputIter& __i, _Distance __n, input_iterator_tag)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIter>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIter>);
while (__n--) ++__i;
}
......@@ -119,7 +119,7 @@ inline void __advance(_BidirectionalIterator& __i, _Distance __n,
bidirectional_iterator_tag)
{
// concept requirements
glibcpp_function_requires(BidirectionalIteratorConcept<_BidirectionalIterator>);
__glibcpp_function_requires(_BidirectionalIteratorConcept<_BidirectionalIterator>);
if (__n >= 0)
while (__n--) ++__i;
else
......@@ -131,7 +131,7 @@ inline void __advance(_RandomAccessIterator& __i, _Distance __n,
random_access_iterator_tag)
{
// concept requirements
glibcpp_function_requires(RandomAccessIteratorConcept<_RandomAccessIterator>);
__glibcpp_function_requires(_RandomAccessIteratorConcept<_RandomAccessIterator>);
__i += __n;
}
......
......@@ -201,7 +201,7 @@ template <class _Tp, class _Alloc = allocator<_Tp> >
class list : protected _List_base<_Tp, _Alloc>
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
typedef _List_base<_Tp, _Alloc> _Base;
protected:
......
......@@ -41,8 +41,8 @@ template <class _Key, class _Tp, class _Compare = less<_Key>,
class map
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires4(_Compare, bool, _Key, _Key, BinaryFunctionConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires4(_Compare, bool, _Key, _Key, _BinaryFunctionConcept);
public:
// typedefs:
......
......@@ -55,8 +55,8 @@ template <class _Key, class _Tp, class _Compare, class _Alloc>
class multimap
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires4(_Compare, bool, _Key, _Key, BinaryFunctionConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires4(_Compare, bool, _Key, _Key, _BinaryFunctionConcept);
public:
......
......@@ -54,8 +54,8 @@ template <class _Key, class _Compare, class _Alloc>
class multiset
{
// concept requirements
glibcpp_class_requires(_Key, SGIAssignableConcept);
glibcpp_class_requires4(_Compare, bool, _Key, _Key, BinaryFunctionConcept);
__glibcpp_class_requires(_Key, _SGIAssignableConcept);
__glibcpp_class_requires4(_Compare, bool, _Key, _Key, _BinaryFunctionConcept);
public:
......
......@@ -39,7 +39,7 @@ template <class _InputIterator, class _Tp>
_Tp accumulate(_InputIterator __first, _InputIterator __last, _Tp __init)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
for ( ; __first != __last; ++__first)
__init = __init + *__first;
......@@ -51,7 +51,7 @@ _Tp accumulate(_InputIterator __first, _InputIterator __last, _Tp __init,
_BinaryOperation __binary_op)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
for ( ; __first != __last; ++__first)
__init = __binary_op(__init, *__first);
......@@ -63,8 +63,8 @@ _Tp inner_product(_InputIterator1 __first1, _InputIterator1 __last1,
_InputIterator2 __first2, _Tp __init)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator1>);
glibcpp_function_requires(InputIteratorConcept<_InputIterator2>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator2>);
for ( ; __first1 != __last1; ++__first1, ++__first2)
__init = __init + (*__first1 * *__first2);
......@@ -79,8 +79,8 @@ _Tp inner_product(_InputIterator1 __first1, _InputIterator1 __last1,
_BinaryOperation2 __binary_op2)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator1>);
glibcpp_function_requires(InputIteratorConcept<_InputIterator2>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator1>);
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator2>);
for ( ; __first1 != __last1; ++__first1, ++__first2)
__init = __binary_op1(__init, __binary_op2(*__first1, *__first2));
......@@ -106,8 +106,8 @@ partial_sum(_InputIterator __first, _InputIterator __last,
_OutputIterator __result)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIterator,
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIterator,
typename iterator_traits<_InputIterator>::value_type>);
if (__first == __last) return __result;
......@@ -135,8 +135,8 @@ partial_sum(_InputIterator __first, _InputIterator __last,
_OutputIterator __result, _BinaryOperation __binary_op)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIterator,
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIterator,
typename iterator_traits<_InputIterator>::value_type>);
if (__first == __last) return __result;
......@@ -165,8 +165,8 @@ adjacent_difference(_InputIterator __first,
_InputIterator __last, _OutputIterator __result)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIterator,
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIterator,
typename iterator_traits<_InputIterator>::value_type>);
if (__first == __last) return __result;
......@@ -196,8 +196,8 @@ adjacent_difference(_InputIterator __first, _InputIterator __last,
_OutputIterator __result, _BinaryOperation __binary_op)
{
// concept requirements
glibcpp_function_requires(InputIteratorConcept<_InputIterator>);
glibcpp_function_requires(OutputIteratorConcept<_OutputIterator,
__glibcpp_function_requires(_InputIteratorConcept<_InputIterator>);
__glibcpp_function_requires(_OutputIteratorConcept<_OutputIterator,
typename iterator_traits<_InputIterator>::value_type>);
if (__first == __last) return __result;
......@@ -262,8 +262,8 @@ void
iota(_ForwardIter __first, _ForwardIter __last, _Tp __value)
{
// concept requirements
glibcpp_function_requires(Mutable_ForwardIteratorConcept<_ForwardIter>);
glibcpp_function_requires(ConvertibleConcept<_Tp,
__glibcpp_function_requires(_Mutable_ForwardIteratorConcept<_ForwardIter>);
__glibcpp_function_requires(_ConvertibleConcept<_Tp,
typename iterator_traits<_ForwardIter>::value_type>);
while (__first != __last)
......
......@@ -53,11 +53,11 @@ template <class _Tp, class _Sequence>
class queue
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires(_Sequence, FrontInsertionSequenceConcept);
glibcpp_class_requires(_Sequence, BackInsertionSequenceConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires(_Sequence, _FrontInsertionSequenceConcept);
__glibcpp_class_requires(_Sequence, _BackInsertionSequenceConcept);
typedef typename _Sequence::value_type _Sequence_value_type;
glibcpp_class_requires2(_Tp, _Sequence_value_type, SameTypeConcept);
__glibcpp_class_requires2(_Tp, _Sequence_value_type, _SameTypeConcept);
template <class _Tp1, class _Seq1>
friend bool operator== (const queue<_Tp1, _Seq1>&,
......@@ -136,12 +136,12 @@ template <class _Tp,
class priority_queue
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires(_Sequence, SequenceConcept);
glibcpp_class_requires(_Sequence, RandomAccessContainerConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires(_Sequence, _SequenceConcept);
__glibcpp_class_requires(_Sequence, _RandomAccessContainerConcept);
typedef typename _Sequence::value_type _Sequence_value_type;
glibcpp_class_requires2(_Tp, _Sequence_value_type, SameTypeConcept);
glibcpp_class_requires4(_Compare, bool, _Tp, _Tp, BinaryFunctionConcept);
__glibcpp_class_requires2(_Tp, _Sequence_value_type, _SameTypeConcept);
__glibcpp_class_requires4(_Compare, bool, _Tp, _Tp, _BinaryFunctionConcept);
public:
typedef typename _Sequence::value_type value_type;
......
......@@ -55,8 +55,8 @@ template <class _Key, class _Compare, class _Alloc>
class set
{
// concept requirements
glibcpp_class_requires(_Key, SGIAssignableConcept);
glibcpp_class_requires4(_Compare, bool, _Key, _Key, BinaryFunctionConcept);
__glibcpp_class_requires(_Key, _SGIAssignableConcept);
__glibcpp_class_requires4(_Compare, bool, _Key, _Key, _BinaryFunctionConcept);
public:
// typedefs:
......
......@@ -53,10 +53,10 @@ template <class _Tp, class _Sequence>
class stack
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires(_Sequence, BackInsertionSequenceConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires(_Sequence, _BackInsertionSequenceConcept);
typedef typename _Sequence::value_type _Sequence_value_type;
glibcpp_class_requires2(_Tp, _Sequence_value_type, SameTypeConcept);
__glibcpp_class_requires2(_Tp, _Sequence_value_type, _SameTypeConcept);
template <class _Tp1, class _Seq1>
friend bool operator== (const stack<_Tp1, _Seq1>&,
......
......@@ -118,7 +118,7 @@ template <class _Tp, class _Alloc = allocator<_Tp> >
class vector : protected _Vector_base<_Tp, _Alloc>
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
private:
typedef _Vector_base<_Tp, _Alloc> _Base;
......
......@@ -204,10 +204,10 @@ template <class _Key, class _Tp, class _HashFcn, class _EqualKey, class _Alloc>
class hash_multimap
{
// concept requirements
glibcpp_class_requires(_Key, SGIAssignableConcept);
glibcpp_class_requires(_Tp, SGIAssignableConcept);
glibcpp_class_requires3(_HashFcn, size_t, _Key, UnaryFunctionConcept);
glibcpp_class_requires3(_EqualKey, _Key, _Key, BinaryPredicateConcept);
__glibcpp_class_requires(_Key, _SGIAssignableConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
__glibcpp_class_requires3(_HashFcn, size_t, _Key, _UnaryFunctionConcept);
__glibcpp_class_requires3(_EqualKey, _Key, _Key, _BinaryPredicateConcept);
private:
typedef hashtable<pair<const _Key, _Tp>, _Key, _HashFcn,
......
......@@ -54,9 +54,9 @@ template <class _Value, class _HashFcn, class _EqualKey, class _Alloc>
class hash_set
{
// concept requirements
glibcpp_class_requires(_Value, SGIAssignableConcept);
glibcpp_class_requires3(_HashFcn, size_t, _Value, UnaryFunctionConcept);
glibcpp_class_requires3(_EqualKey, _Value, _Value, BinaryPredicateConcept);
__glibcpp_class_requires(_Value, _SGIAssignableConcept);
__glibcpp_class_requires3(_HashFcn, size_t, _Value, _UnaryFunctionConcept);
__glibcpp_class_requires3(_EqualKey, _Value, _Value, _BinaryPredicateConcept);
private:
typedef hashtable<_Value, _Value, _HashFcn, _Identity<_Value>,
......@@ -205,9 +205,9 @@ template <class _Value, class _HashFcn, class _EqualKey, class _Alloc>
class hash_multiset
{
// concept requirements
glibcpp_class_requires(_Value, SGIAssignableConcept);
glibcpp_class_requires3(_HashFcn, size_t, _Value, UnaryFunctionConcept);
glibcpp_class_requires3(_EqualKey, _Value, _Value, BinaryPredicateConcept);
__glibcpp_class_requires(_Value, _SGIAssignableConcept);
__glibcpp_class_requires3(_HashFcn, size_t, _Value, _UnaryFunctionConcept);
__glibcpp_class_requires3(_EqualKey, _Value, _Value, _BinaryPredicateConcept);
private:
typedef hashtable<_Value, _Value, _HashFcn, _Identity<_Value>,
......
......@@ -258,7 +258,7 @@ template <class _Tp, class _Alloc = allocator<_Tp> >
class slist : private _Slist_base<_Tp,_Alloc>
{
// concept requirements
glibcpp_class_requires(_Tp, SGIAssignableConcept);
__glibcpp_class_requires(_Tp, _SGIAssignableConcept);
private:
typedef _Slist_base<_Tp,_Alloc> _Base;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment