std::tuple does not have constexpr constructors (besides the default one), at least not in C++11 and C++14 which are supported by this library. A custom class would guarantee static initialization and avoid the "static initialization order fiasco" (which, in fact, applies to dynamic initialization of nonlocal variables, but whatever).
Also, it would allow slicing the copy constructor from function "vtables," to produce tables compatible with unique_function even if the latter doesn't have a slot for copy constructors. (Actually, that optimization may be too minor to bother with.)
std::tuple
does not haveconstexpr
constructors (besides the default one), at least not in C++11 and C++14 which are supported by this library. A custom class would guarantee static initialization and avoid the "static initialization order fiasco" (which, in fact, applies to dynamic initialization of nonlocal variables, but whatever).Also, it would allow slicing the copy constructor from
function
"vtables," to produce tables compatible withunique_function
even if the latter doesn't have a slot for copy constructors. (Actually, that optimization may be too minor to bother with.)