23 template<
typename _Tuple,
typename _Fn,
size_t... _Idx>
25 tuple_visitor_impl(_Tuple && t, _Fn && f, std::index_sequence<_Idx...>) {
34 auto _l = {(f(_Idx, std::get<_Idx>(t)), 0)...};
50 template<
typename _Tuple,
typename _Fn>
54 std::make_index_sequence<std::tuple_size_v<std::decay_t<_Tuple>>>;
56 tuple_visitor_impl(std::forward<_Tuple>(t), std::forward<_Fn>(f), _Indices{});
73 template<
typename _Tuple,
typename _Fn>
76 static_assert(std::is_default_constructible<_Tuple>::value,
77 "tuple_vist tuple type is not default constructible");
80 std::make_index_sequence<std::tuple_size_v<std::decay_t<_Tuple>>>;
83 std::forward<_Tuple>({}), std::forward<_Fn>(f), _Indices{});
void tuple_visitor(_Tuple &&t, _Fn &&f)
Definition: tuple_visitor.hh:52
Definition: control.hh:31