libycxx

function object

std::ranges::fold_right

Scope
std::ranges

Synopsis

inline constexpr /* implementation-defined */ fold_right = {};

Call signatures

fold_right is a function object; these are its call operators as libycxx declares them, written as the functions the draft declares.

  1. template<
        std::ranges::bidirectional_range R,
        class T = std::ranges::range_value_t<R>,
        indirectly-binary-right-foldable<T, iterator_t<R>> F>
    constexpr auto fold_right(R&& r, T init, F f);
    (1)
  2. template<
        std::bidirectional_iterator I,
        std::sentinel_for<I> S,
        class T = std::iter_value_t<I>,
        indirectly-binary-right-foldable<T, I> F>
    constexpr auto fold_right(I first, S last, T init, F f);
    (2)