Пример #1
0
 void next(range_iterator_t<Rng> &it)
 {
     if(++it != ranges::end(rng_->mutable_base()))
     {
         sum_ = rng_->fun_(*sum_, *it);
     }
 }
Пример #2
0
 void next(range_iterator_t<Rng> &it)
 {
     using R = range_common_reference_t<Rng>;
     if(++it != ranges::end(rng_->mutable_base()))
     {
         sum_ = rng_->fun_(R(*sum_), R(*it));
     }
 }