Lines Matching refs:__first
159 accumulate(_InputIterator __first, _InputIterator __last, _Tp __init)
161 for (; __first != __last; ++__first)
162 __init = __init + *__first;
169 accumulate(_InputIterator __first, _InputIterator __last, _Tp __init, _BinaryOperation __binary_op)
171 for (; __first != __last; ++__first)
172 __init = __binary_op(__init, *__first);
180 reduce(_InputIterator __first, _InputIterator __last, _Tp __init, _BinaryOp __b)
182 for (; __first != __last; ++__first)
183 __init = __b(__init, *__first);
190 reduce(_InputIterator __first, _InputIterator __last, _Tp __init)
192 return _VSTD::reduce(__first, __last, __init, _VSTD::plus<>());
198 reduce(_InputIterator __first, _InputIterator __last)
200 return _VSTD::reduce(__first, __last,
230 transform_reduce(_InputIterator __first, _InputIterator __last,
233 for (; __first != __last; ++__first)
234 __init = __b(__init, __u(*__first));
264 partial_sum(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
266 if (__first != __last)
268 typename iterator_traits<_InputIterator>::value_type __t(*__first);
270 for (++__first, (void) ++__result; __first != __last; ++__first, (void) ++__result)
272 __t = __t + *__first;
282 partial_sum(_InputIterator __first, _InputIterator __last, _OutputIterator __result,
285 if (__first != __last)
287 typename iterator_traits<_InputIterator>::value_type __t(*__first);
289 for (++__first, (void) ++__result; __first != __last; ++__first, (void) ++__result)
291 __t = __binary_op(__t, *__first);
302 exclusive_scan(_InputIterator __first, _InputIterator __last,
305 if (__first != __last)
310 __init = __b(__init, *__first);
314 } while (++__first != __last);
322 exclusive_scan(_InputIterator __first, _InputIterator __last,
325 return _VSTD::exclusive_scan(__first, __last, __result, __init, _VSTD::plus<>());
329 _OutputIterator inclusive_scan(_InputIterator __first, _InputIterator __last,
332 for (; __first != __last; ++__first, (void) ++__result) {
333 __init = __b(__init, *__first);
340 _OutputIterator inclusive_scan(_InputIterator __first, _InputIterator __last,
343 if (__first != __last) {
344 typename std::iterator_traits<_InputIterator>::value_type __init = *__first;
346 if (++__first != __last)
347 return _VSTD::inclusive_scan(__first, __last, __result, __b, __init);
354 _OutputIterator inclusive_scan(_InputIterator __first, _InputIterator __last,
357 return _VSTD::inclusive_scan(__first, __last, __result, std::plus<>());
364 transform_exclusive_scan(_InputIterator __first, _InputIterator __last,
368 if (__first != __last)
373 __init = __b(__init, __u(*__first));
377 } while (++__first != __last);
383 _OutputIterator transform_inclusive_scan(_InputIterator __first, _InputIterator __last,
386 for (; __first != __last; ++__first, (void) ++__result) {
387 __init = __b(__init, __u(*__first));
395 _OutputIterator transform_inclusive_scan(_InputIterator __first, _InputIterator __last,
398 if (__first != __last) {
399 typename std::iterator_traits<_InputIterator>::value_type __init = __u(*__first);
401 if (++__first != __last)
402 return _VSTD::transform_inclusive_scan(__first, __last, __result, __b, __u, __init);
412 adjacent_difference(_InputIterator __first, _InputIterator __last, _OutputIterator __result)
414 if (__first != __last)
416 typename iterator_traits<_InputIterator>::value_type __t1(*__first);
418 for (++__first, (void) ++__result; __first != __last; ++__first, (void) ++__result)
420 typename iterator_traits<_InputIterator>::value_type __t2(*__first);
431 adjacent_difference(_InputIterator __first, _InputIterator __last, _OutputIterator __result,
434 if (__first != __last)
436 typename iterator_traits<_InputIterator>::value_type __t1(*__first);
438 for (++__first, (void) ++__result; __first != __last; ++__first, (void) ++__result)
440 typename iterator_traits<_InputIterator>::value_type __t2(*__first);
451 iota(_ForwardIterator __first, _ForwardIterator __last, _Tp __value_)
453 for (; __first != __last; ++__first, (void) ++__value_)
454 *__first = __value_;