kumi v3.1.0
Exquisite Epidote
Loading...
Searching...
No Matches

◆ fill()

template<std::size_t N, typename T>
auto kumi::fill ( T const & v)
inlinenodiscardconstexprnoexcept

Creates a kumi::tuple containing N copies of v.

Template Parameters
NNumber of replications
Parameters
vValue to replicate
Returns
A tuple containing N copy of v

Helper type

namespace kumi::result
{
template<std::size_t N, typename T> struct fill;
template<std::size_t N, typename T>
using fill_t = typename fill<N, T>::type;
}
constexpr auto fill(T const &v) noexcept
Creates a kumi::tuple containing N copies of v.
Definition generate.hpp:36

Computes the return type of a call to kumi::fill

Example

#include <kumi/kumi.hpp>
#include <iostream>
int main()
{
std::cout << kumi::fill<7>(42.63) << "\n";
}