Lines Matching refs:__i
1221 _ForwardIterator __i = __first;
1222 while (++__i != __last)
1224 if (__pred(*__first, *__i))
1226 __first = __i;
1418 for (_ForwardIterator1 __i = __first1; __i != __last1; ++__i)
1420 // Have we already counted the number of *__i in [f1, l1)?
1422 for (; __match != __i; ++__match)
1423 if (__pred(*__match, *__i))
1425 if (__match == __i) {
1426 // Count number of *__i in [f2, l2)
1429 if (__pred(*__i, *__j))
1433 // Count number of *__i in [__i, l1) (we can start with 1)
1435 for (_ForwardIterator1 __j = _VSTD::next(__i); __j != __last1; ++__j)
1436 if (__pred(*__i, *__j))
1483 for (_ForwardIterator1 __i = __first1; __i != __last1; ++__i)
1485 // Have we already counted the number of *__i in [f1, l1)?
1487 for (; __match != __i; ++__match)
1488 if (__pred(*__match, *__i))
1490 if (__match == __i) {
1491 // Count number of *__i in [f2, l2)
1494 if (__pred(*__i, *__j))
1498 // Count number of *__i in [__i, l1) (we can start with 1)
1500 for (_ForwardIterator1 __j = _VSTD::next(__i); __j != __last1; ++__j)
1501 if (__pred(*__i, *__j))
1691 __unwrap_iter(_Iter __i)
1693 return __i;
1703 __unwrap_iter(move_iterator<_Tp*> __i)
1705 return __i.base();
1717 __unwrap_iter(__wrap_iter<_Tp*> __i)
1719 return __i.base();
1731 __unwrap_iter(__wrap_iter<_Tp*> __i)
1733 return __i;
2115 _ForwardIterator __i = __first;
2116 while (++__i != __last)
2118 if (!(*__i == __value_))
2120 *__first = _VSTD::move(*__i);
2138 _ForwardIterator __i = __first;
2139 while (++__i != __last)
2141 if (!__pred(*__i))
2143 *__first = _VSTD::move(*__i);
2199 _ForwardIterator __i = __first;
2200 for (++__i; ++__i != __last;)
2201 if (!__pred(*__first, *__i))
2202 *++__first = _VSTD::move(*__i);
2249 _ForwardIterator __i = __first;
2250 *__result = *__i;
2254 if (!__pred(*__i, *__first))
2258 __i = __first;
2376 _ForwardIterator __i = __middle;
2379 swap(*__first, *__i);
2381 if (++__i == __last)
2384 __middle = __i;
2389 __i = __middle;
2392 swap(*__first, *__i);
2394 if (++__i == __last)
2398 __i = __middle;
2401 __middle = __i;
2538 _ForwardIterator __i = __first;
2539 while (++__i != __last)
2540 if (__comp(*__i, *__first))
2541 __first = __i;
2602 _ForwardIterator __i = __first;
2603 while (++__i != __last)
2604 if (__comp(*__first, *__i))
2605 __first = __i;
2697 _ForwardIterator __i = __first;
2700 if (__comp(*__i, *__result.first))
2701 __result.first = __i;
2702 else if (!__comp(*__i, *__result.second))
2703 __result.second = __i;
2708 if (__comp(*__first, *__i))
2712 if (!__comp(*__i, *__result.second))
2713 __result.second = __i;
2717 if (__comp(*__i, *__result.first))
2718 __result.first = __i;
3096 difference_type __i = __uid(__g, _Pp(0, __d));
3097 if (__i != difference_type(0))
3098 swap(*__first, *(__first + __i));
3118 difference_type __i = __rand(__d);
3119 swap(*__first, *(__first + __i));
3214 difference_type __i = __uid(__g, _Pp(0, __d));
3215 if (__i != difference_type(0))
3216 swap(*__first, *(__first + __i));
3377 _ForwardIterator __i = __first;
3378 while (++__i != __last)
3380 if (__pred(*__i))
3382 *__first = _VSTD::move(*__i);
3387 ::new(__t) value_type(_VSTD::move(*__i));
3394 __i = __first;
3395 for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i)
3396 *__i = _VSTD::move(*__t2);
3507 _BidirectionalIterator __i = __first;
3508 while (++__i != __last)
3510 if (__pred(*__i))
3512 *__first = _VSTD::move(*__i);
3517 ::new(__t) value_type(_VSTD::move(*__i));
3523 *__first = _VSTD::move(*__i);
3524 __i = ++__first;
3527 for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i)
3528 *__i = _VSTD::move(*__t2);
3635 _ForwardIterator __i = __first;
3636 while (++__i != __last)
3638 if (__comp(*__i, *__first))
3639 return __i;
3640 __first = __i;
3776 _BirdirectionalIterator __i = _VSTD::min_element<_BirdirectionalIterator,
3779 if (__i != __first)
3780 swap(*__first, *__i);
3791 _BirdirectionalIterator __i = __first;
3792 for (++__i; __i != __last; ++__i)
3794 _BirdirectionalIterator __j = __i;
3796 for (_BirdirectionalIterator __k = __i; __k != __first && __comp(__t, *--__k); --__j)
3810 for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i)
3812 if (__comp(*__i, *__j))
3814 value_type __t(_VSTD::move(*__i));
3816 __j = __i;
3824 __j = __i;
3856 for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i)
3858 if (__comp(*__i, *__j))
3860 value_type __t(_VSTD::move(*__i));
3862 __j = __i;
3870 return ++__i == __last;
3872 __j = __i;
3973 _RandomAccessIterator __i = __first;
3978 if (!__comp(*__i, *__m)) // if *__first == *__m
3981 // manually guard downward moving __j against __i
3984 if (__i == --__j)
3987 // Parition instead into [__first, __i) == *__first and *__first < [__i, __last)
3988 ++__i; // __first + 1
3994 if (__i == __j)
3996 if (__comp(*__first, *__i))
3998 swap(*__i, *__j);
4000 ++__i;
4003 ++__i;
4006 // [__first, __i) == *__first and *__first < [__j, __last) and __j == __last - 1
4007 if (__i == __j)
4011 while (!__comp(*__first, *__i))
4012 ++__i;
4015 if (__i >= __j)
4017 swap(*__i, *__j);
4019 ++__i;
4021 // [__first, __i) == *__first and *__first < [__i, __last)
4023 // _VSTD::__sort<_Compare>(__i, __last, __comp);
4024 __first = __i;
4029 swap(*__i, *__j);
4035 // It is known that *__i < *__m
4036 ++__i;
4039 if (__i < __j)
4041 // known that *(__i - 1) < *__m
4042 // known that __i <= __m
4045 // __m still guards upward moving __i
4046 while (__comp(*__i, *__m))
4047 ++__i;
4051 if (__i > __j)
4053 swap(*__i, *__j);
4057 if (__m == __i)
4059 ++__i;
4062 // [__first, __i) < *__m and *__m <= [__i, __last)
4063 if (__i != __m && __comp(*__m, *__i))
4065 swap(*__i, *__m);
4068 // [__first, __i) < *__i and *__i <= [__i+1, __last)
4072 bool __fs = _VSTD::__insertion_sort_incomplete<_Compare>(__first, __i, __comp);
4073 if (_VSTD::__insertion_sort_incomplete<_Compare>(__i+1, __last, __comp))
4077 __last = __i;
4084 __first = ++__i;
4090 if (__i - __first < __last - __i)
4092 _VSTD::__sort<_Compare>(__first, __i, __comp);
4093 // _VSTD::__sort<_Compare>(__i+1, __last, __comp);
4094 __first = ++__i;
4098 _VSTD::__sort<_Compare>(__i+1, __last, __comp);
4099 // _VSTD::__sort<_Compare>(__first, __i, __comp);
4100 __last = __i;
4474 …for (_BidirectionalIterator __i = __first; __i != __middle; __d.__incr((value_type*)0), (void) ++_…
4475 ::new(__p) value_type(_VSTD::move(*__i));
4481 …for (_BidirectionalIterator __i = __middle; __i != __last; __d.__incr((value_type*)0), (void) ++__…
4482 ::new(__p) value_type(_VSTD::move(*__i));
5106 for (_RandomAccessIterator __i = __middle; __i != __last; ++__i)
5108 if (__comp(*__i, *__first))
5110 swap(*__i, *__first);
5236 _RandomAccessIterator __i = __first;
5241 if (!__comp(*__i, *__m)) // if *__first == *__m
5244 // manually guard downward moving __j against __i
5247 if (__i == --__j)
5250 // Parition instead into [__first, __i) == *__first and *__first < [__i, __last)
5251 ++__i; // __first + 1
5257 if (__i == __j)
5259 if (__comp(*__first, *__i))
5261 swap(*__i, *__j);
5263 ++__i;
5266 ++__i;
5269 // [__first, __i) == *__first and *__first < [__j, __last) and __j == __last - 1
5270 if (__i == __j)
5274 while (!__comp(*__first, *__i))
5275 ++__i;
5278 if (__i >= __j)
5280 swap(*__i, *__j);
5282 ++__i;
5284 // [__first, __i) == *__first and *__first < [__i, __last)
5286 if (__nth < __i)
5289 // __nth_element<_Compare>(__i, __nth, __last, __comp);
5290 __first = __i;
5295 swap(*__i, *__j);
5301 ++__i;
5304 if (__i < __j)
5306 // known that *(__i - 1) < *__m
5309 // __m still guards upward moving __i
5310 while (__comp(*__i, *__m))
5311 ++__i;
5315 if (__i >= __j)
5317 swap(*__i, *__j);
5321 if (__m == __i)
5323 ++__i;
5326 // [__first, __i) < *__m and *__m <= [__i, __last)
5327 if (__i != __m && __comp(*__m, *__i))
5329 swap(*__i, *__m);
5332 // [__first, __i) < *__i and *__i <= [__i+1, __last)
5333 if (__nth == __i)
5338 if (__nth < __i)
5340 // Check for [__first, __i) already sorted
5342 while (++__j != __i)
5349 // [__first, __i) sorted
5354 // Check for [__i, __last) already sorted
5355 __j = __m = __i;
5363 // [__i, __last) sorted
5369 if (__nth < __i)
5371 // __nth_element<_Compare>(__first, __nth, __i, __comp);
5372 __last = __i;
5376 // __nth_element<_Compare>(__i+1, __nth, __last, __comp);
5377 __first = ++__i;
5717 _BidirectionalIterator __i = __last;
5718 if (__first == __last || __first == --__i)
5722 _BidirectionalIterator __ip1 = __i;
5723 if (__comp(*--__i, *__ip1))
5726 while (!__comp(*__i, *--__j))
5728 swap(*__i, *__j);
5732 if (__i == __first)
5770 _BidirectionalIterator __i = __last;
5771 if (__first == __last || __first == --__i)
5775 _BidirectionalIterator __ip1 = __i;
5776 if (__comp(*__ip1, *--__i))
5779 while (!__comp(*--__j, *__i))
5781 swap(*__i, *__j);
5785 if (__i == __first)