SILICON
Loading...
Searching...
No Matches
SILICON::views Namespace Reference

Functions

template<typename R>
auto operator| (R &&r, decltype(SILICON::views::enumerate))

Variables

template<std::size_t N>
constexpr auto adjacent
constexpr auto slide = ranges::views::sliding
constexpr auto chunk = ranges::views::chunk

Function Documentation

◆ operator|()

template<typename R>
auto operator| ( R && r,
decltype(SILICON::views::enumerate)  )

Definition at line 66 of file ranges_wrapper.hpp.

Variable Documentation

◆ adjacent

template<std::size_t N>
auto adjacent
inlineconstexpr
Initial value:
= ranges::make_pipeable([](auto&& r) {
if constexpr (N == 0) {
return ranges::views::empty<std::tuple<>>;
} else {
return std::forward<decltype(r)>(r) | ranges::views::sliding(N)
| ranges::views::transform([](auto window) {
return [&]<std::size_t... I>(std::index_sequence<I...>) {
return std::tuple<decltype(*ranges::next(ranges::begin(window), I))...>(
*ranges::next(ranges::begin(window), I)...);
}(std::make_index_sequence<N>{});
});
}
})

Definition at line 44 of file ranges_wrapper.hpp.

◆ chunk

auto chunk = ranges::views::chunk
inlineconstexpr

Definition at line 81 of file ranges_wrapper.hpp.

◆ slide

auto slide = ranges::views::sliding
inlineconstexpr

Definition at line 75 of file ranges_wrapper.hpp.