This is a mythical beast we discussed in a previous question:
template <typename F, class Tuple>
constexpr void operator|(Tuple&& t, F f) noexcept(noexcept(f(std::get<0>(t))))
{
[&]<auto ...I>(std::index_sequence<I...>) noexcept(noexcept(f(std::get<0>(t))))
{
(f(std::get<I>(t)), ...);
}
(std::make_index_sequence<std::tuple_size_v<std::remove_reference_t<Tuple>>>());
}
Usage:
std::forward_as_tuple(1, 2, 3) | [](auto&& v) { std::cout << v << std::endl; };
https://wandbox.org/permlink/WMd80R2njgpubRvi
You could pipe all sorts of things into a function, not just a tuple. Arrays, containers, variants, ..., even structs.