diff options
author | paolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-07-04 07:22:19 +0000 |
---|---|---|
committer | paolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-07-04 07:22:19 +0000 |
commit | 09f23ccf5de2fca0613ebf5d967cb27a40c97b0e (patch) | |
tree | 01436baf36c5ba8a651392191c153d791273aa09 /libstdc++-v3 | |
parent | e04e588b0855c4ec572c1165731b58b03b3cf52c (diff) | |
download | ppe42-gcc-09f23ccf5de2fca0613ebf5d967cb27a40c97b0e.tar.gz ppe42-gcc-09f23ccf5de2fca0613ebf5d967cb27a40c97b0e.zip |
2003-07-04 Paolo Carlini <pcarlini@unitus.it>
* include/bits/stl_heap.h: Fully qualify standard
functions with std::, thus avoiding Koenig lookup.
* include/bits/stl_iterator_base_funcs.h: Likewise.
* include/bits/stl_algo.h: Qualify __iterator_category too.
* include/bits/stl_algobase.h: Likewise.
* include/bits/stl_bvector.h: Likewise.
* include/bits/stl_algo.h: Don't qualify the pair type.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68915 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 12 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/stl_algo.h | 24 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/stl_algobase.h | 10 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/stl_bvector.h | 6 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/stl_heap.h | 32 | ||||
-rw-r--r-- | libstdc++-v3/include/bits/stl_iterator_base_funcs.h | 6 |
6 files changed, 51 insertions, 39 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 10162cce113..cc34c60efeb 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,15 @@ +2003-07-04 Paolo Carlini <pcarlini@unitus.it> + + * include/bits/stl_heap.h: Fully qualify standard + functions with std::, thus avoiding Koenig lookup. + * include/bits/stl_iterator_base_funcs.h: Likewise. + + * include/bits/stl_algo.h: Qualify __iterator_category too. + * include/bits/stl_algobase.h: Likewise. + * include/bits/stl_bvector.h: Likewise. + + * include/bits/stl_algo.h: Don't qualify the pair type. + 2003-07-03 Benjamin Kosnik <bkoz@redhat.com> * include/Makefile.am (target_headers): Add fpos.h diff --git a/libstdc++-v3/include/bits/stl_algo.h b/libstdc++-v3/include/bits/stl_algo.h index a43c17ac1fb..3b00005939a 100644 --- a/libstdc++-v3/include/bits/stl_algo.h +++ b/libstdc++-v3/include/bits/stl_algo.h @@ -295,7 +295,7 @@ namespace std __glibcpp_function_requires(_InputIteratorConcept<_InputIterator>) __glibcpp_function_requires(_EqualOpConcept< typename iterator_traits<_InputIterator>::value_type, _Tp>) - return std::find(__first, __last, __val, __iterator_category(__first)); + return std::find(__first, __last, __val, std::__iterator_category(__first)); } /** @@ -315,7 +315,7 @@ namespace std __glibcpp_function_requires(_InputIteratorConcept<_InputIterator>) __glibcpp_function_requires(_UnaryPredicateConcept<_Predicate, typename iterator_traits<_InputIterator>::value_type>) - return std::find_if(__first, __last, __pred, __iterator_category(__first)); + return std::find_if(__first, __last, __pred, std::__iterator_category(__first)); } /** @@ -1352,7 +1352,7 @@ namespace std // concept requirements __glibcpp_function_requires(_Mutable_BidirectionalIteratorConcept< _BidirectionalIterator>) - std::__reverse(__first, __last, __iterator_category(__first)); + std::__reverse(__first, __last, std::__iterator_category(__first)); } /** @@ -1754,7 +1754,7 @@ namespace std __glibcpp_function_requires(_UnaryPredicateConcept<_Predicate, typename iterator_traits<_ForwardIterator>::value_type>) - return std::__partition(__first, __last, __pred, __iterator_category(__first)); + return std::__partition(__first, __last, __pred, std::__iterator_category(__first)); } @@ -3469,10 +3469,10 @@ namespace std __left = std::lower_bound(__first, __middle, __val); std::advance(__first, __len); __right = std::upper_bound(++__middle, __first, __val); - return std::pair<_ForwardIterator, _ForwardIterator>(__left, __right); + return pair<_ForwardIterator, _ForwardIterator>(__left, __right); } } - return std::pair<_ForwardIterator, _ForwardIterator>(__first, __first); + return pair<_ForwardIterator, _ForwardIterator>(__first, __first); } /** @@ -3524,10 +3524,10 @@ namespace std __left = std::lower_bound(__first, __middle, __val, __comp); std::advance(__first, __len); __right = std::upper_bound(++__middle, __first, __val, __comp); - return std::pair<_ForwardIterator, _ForwardIterator>(__left, __right); + return pair<_ForwardIterator, _ForwardIterator>(__left, __right); } } - return std::pair<_ForwardIterator, _ForwardIterator>(__first, __first); + return pair<_ForwardIterator, _ForwardIterator>(__first, __first); } /** @@ -4320,8 +4320,8 @@ namespace std typename iterator_traits<_ForwardIterator2>::value_type>) return std::__find_end(__first1, __last1, __first2, __last2, - __iterator_category(__first1), - __iterator_category(__first2)); + std::__iterator_category(__first1), + std::__iterator_category(__first2)); } template<typename _ForwardIterator1, typename _ForwardIterator2, @@ -4339,8 +4339,8 @@ namespace std typename iterator_traits<_ForwardIterator2>::value_type>) return std::__find_end(__first1, __last1, __first2, __last2, - __iterator_category(__first1), - __iterator_category(__first2), + std::__iterator_category(__first1), + std::__iterator_category(__first2), __comp); } diff --git a/libstdc++-v3/include/bits/stl_algobase.h b/libstdc++-v3/include/bits/stl_algobase.h index 689953287a1..3c68c425c32 100644 --- a/libstdc++-v3/include/bits/stl_algobase.h +++ b/libstdc++-v3/include/bits/stl_algobase.h @@ -248,13 +248,13 @@ namespace std inline _OutputIterator __copy_aux2(_InputIterator __first, _InputIterator __last, _OutputIterator __result, __false_type) - { return std::__copy(__first, __last, __result, __iterator_category(__first)); } + { return std::__copy(__first, __last, __result, std::__iterator_category(__first)); } template<typename _InputIterator, typename _OutputIterator> inline _OutputIterator __copy_aux2(_InputIterator __first, _InputIterator __last, _OutputIterator __result, __true_type) - { return std::__copy(__first, __last, __result, __iterator_category(__first)); } + { return std::__copy(__first, __last, __result, std::__iterator_category(__first)); } template<typename _Tp> inline _Tp* @@ -370,7 +370,7 @@ namespace std _BidirectionalIterator2 __result) { return std::__copy_backward(__first, __last, __result, - __iterator_category(__first)); + std::__iterator_category(__first)); } }; @@ -594,7 +594,7 @@ namespace std ++__first1; ++__first2; } - return std::pair<_InputIterator1, _InputIterator2>(__first1, __first2); + return pair<_InputIterator1, _InputIterator2>(__first1, __first2); } /** @@ -625,7 +625,7 @@ namespace std ++__first1; ++__first2; } - return std::pair<_InputIterator1, _InputIterator2>(__first1, __first2); + return pair<_InputIterator1, _InputIterator2>(__first1, __first2); } /** diff --git a/libstdc++-v3/include/bits/stl_bvector.h b/libstdc++-v3/include/bits/stl_bvector.h index e8f8b0da82c..3f6c2a22463 100644 --- a/libstdc++-v3/include/bits/stl_bvector.h +++ b/libstdc++-v3/include/bits/stl_bvector.h @@ -522,7 +522,7 @@ template <typename _Alloc> template <class _InputIterator> void _M_initialize_dispatch(_InputIterator __first, _InputIterator __last, __false_type) { - _M_initialize_range(__first, __last, __iterator_category(__first)); + _M_initialize_range(__first, __last, std::__iterator_category(__first)); } template <class _InputIterator> @@ -577,7 +577,7 @@ template <typename _Alloc> template <class _InputIterator> void _M_assign_dispatch(_InputIterator __first, _InputIterator __last, __false_type) - { _M_assign_aux(__first, __last, __iterator_category(__first)); } + { _M_assign_aux(__first, __last, std::__iterator_category(__first)); } template <class _InputIterator> void _M_assign_aux(_InputIterator __first, _InputIterator __last, @@ -662,7 +662,7 @@ template <typename _Alloc> void _M_insert_dispatch(iterator __pos, _InputIterator __first, _InputIterator __last, __false_type) { - _M_insert_range(__pos, __first, __last, __iterator_category(__first)); + _M_insert_range(__pos, __first, __last, std::__iterator_category(__first)); } template <class _InputIterator> diff --git a/libstdc++-v3/include/bits/stl_heap.h b/libstdc++-v3/include/bits/stl_heap.h index c19195aad39..8105ff05719 100644 --- a/libstdc++-v3/include/bits/stl_heap.h +++ b/libstdc++-v3/include/bits/stl_heap.h @@ -93,8 +93,8 @@ namespace std _RandomAccessIterator>) __glibcpp_function_requires(_LessThanComparableConcept<_ValueType>) - __push_heap(__first, _DistanceType((__last - __first) - 1), _DistanceType(0), - _ValueType(*(__last - 1))); + std::__push_heap(__first, _DistanceType((__last - __first) - 1), _DistanceType(0), + _ValueType(*(__last - 1))); } template<typename _RandomAccessIterator, typename _Distance, typename _Tp, @@ -126,8 +126,8 @@ namespace std __glibcpp_function_requires(_Mutable_RandomAccessIteratorConcept< _RandomAccessIterator>) - __push_heap(__first, _DistanceType((__last - __first) - 1), _DistanceType(0), - _ValueType(*(__last - 1)), __comp); + std::__push_heap(__first, _DistanceType((__last - __first) - 1), _DistanceType(0), + _ValueType(*(__last - 1)), __comp); } template<typename _RandomAccessIterator, typename _Distance, typename _Tp> @@ -148,7 +148,7 @@ namespace std *(__first + __holeIndex) = *(__first + (__secondChild - 1)); __holeIndex = __secondChild - 1; } - __push_heap(__first, __holeIndex, __topIndex, __value); + std::__push_heap(__first, __holeIndex, __topIndex, __value); } template<typename _RandomAccessIterator, typename _Tp> @@ -158,7 +158,7 @@ namespace std { typedef typename iterator_traits<_RandomAccessIterator>::difference_type _Distance; *__result = *__first; - __adjust_heap(__first, _Distance(0), _Distance(__last - __first), __value); + std::__adjust_heap(__first, _Distance(0), _Distance(__last - __first), __value); } template<typename _RandomAccessIterator> @@ -172,7 +172,7 @@ namespace std _RandomAccessIterator>) __glibcpp_function_requires(_LessThanComparableConcept<_ValueType>) - __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last - 1))); + std::__pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last - 1))); } template<typename _RandomAccessIterator, typename _Distance, @@ -194,7 +194,7 @@ namespace std *(__first + __holeIndex) = *(__first + (__secondChild - 1)); __holeIndex = __secondChild - 1; } - __push_heap(__first, __holeIndex, __topIndex, __value, __comp); + std::__push_heap(__first, __holeIndex, __topIndex, __value, __comp); } template<typename _RandomAccessIterator, typename _Tp, typename _Compare> @@ -204,8 +204,8 @@ namespace std { typedef typename iterator_traits<_RandomAccessIterator>::difference_type _Distance; *__result = *__first; - __adjust_heap(__first, _Distance(0), _Distance(__last - __first), - __value, __comp); + std::__adjust_heap(__first, _Distance(0), _Distance(__last - __first), + __value, __comp); } template<typename _RandomAccessIterator, typename _Compare> @@ -218,7 +218,7 @@ namespace std _RandomAccessIterator>) typedef typename iterator_traits<_RandomAccessIterator>::value_type _ValueType; - __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last - 1)), __comp); + std::__pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last - 1)), __comp); } template<typename _RandomAccessIterator> @@ -240,7 +240,7 @@ namespace std _DistanceType __parent = (__len - 2)/2; while (true) { - __adjust_heap(__first, __parent, __len, _ValueType(*(__first + __parent))); + std::__adjust_heap(__first, __parent, __len, _ValueType(*(__first + __parent))); if (__parent == 0) return; __parent--; } @@ -265,8 +265,8 @@ namespace std _DistanceType __parent = (__len - 2)/2; while (true) { - __adjust_heap(__first, __parent, __len, - _ValueType(*(__first + __parent)), __comp); + std::__adjust_heap(__first, __parent, __len, + _ValueType(*(__first + __parent)), __comp); if (__parent == 0) return; __parent--; } @@ -283,7 +283,7 @@ namespace std typename iterator_traits<_RandomAccessIterator>::value_type>) while (__last - __first > 1) - pop_heap(__first, __last--); + std::pop_heap(__first, __last--); } template<typename _RandomAccessIterator, typename _Compare> @@ -296,7 +296,7 @@ namespace std _RandomAccessIterator>) while (__last - __first > 1) - pop_heap(__first, __last--, __comp); + std::pop_heap(__first, __last--, __comp); } } // namespace std diff --git a/libstdc++-v3/include/bits/stl_iterator_base_funcs.h b/libstdc++-v3/include/bits/stl_iterator_base_funcs.h index 8ea22a0a7e5..53cf23490a9 100644 --- a/libstdc++-v3/include/bits/stl_iterator_base_funcs.h +++ b/libstdc++-v3/include/bits/stl_iterator_base_funcs.h @@ -1,6 +1,6 @@ // Functions used by iterators -*- C++ -*- -// Copyright (C) 2001, 2002 Free Software Foundation, Inc. +// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -111,7 +111,7 @@ namespace std distance(_InputIterator __first, _InputIterator __last) { // concept requirements -- taken care of in __distance - return __distance(__first, __last, __iterator_category(__first)); + return std::__distance(__first, __last, std::__iterator_category(__first)); } template<typename _InputIterator, typename _Distance> @@ -164,7 +164,7 @@ namespace std advance(_InputIterator& __i, _Distance __n) { // concept requirements -- taken care of in __advance - __advance(__i, __n, __iterator_category(__i)); + std::__advance(__i, __n, std::__iterator_category(__i)); } } // namespace std |