Beispiel #1
0
 static constexpr auto apply(X&& x, N const&) {
     constexpr std::size_t n = hana::value<N>();
     return repeat_helper(static_cast<X&&>(x),
                          std::make_index_sequence<n>{});
 }
 static constexpr auto apply(N const&, F&& f) {
     static_assert(N::value >= 0, "hana::repeat(n, f) requires 'n' to be non-negative");
     constexpr std::size_t n = N::value;
     repeat_helper(static_cast<F&&>(f), std::make_index_sequence<n>{});
 }