template<typename... Ts>
struct kumi::common_product_type< Ts >
Extracts the common product_type of a parameter pack.
- Note
- If the pack is empty, there is no common product type to build and the type alias is not defined.
If all the types are record types then it returns an empty record type, otherwise returns an empty product type. As we are unable to properly compute the Least Restrictive Subtype of a pack this trait is specialized in the following way.
- Note
- It is used in algorithm taking multiple product types as input in order to determine the correct output type.
- Template Parameters
-
| Ts | The product types to access |
Helper type
{
template<
typename... Ts>
using common_product_type_t =
typename common_product_type<Ts...>::type;
}
Main KUMI namespace.
Definition algorithm.hpp:11
Extracts the common product_type of a parameter pack.
Definition traits.hpp:585