Pretty Good Sum Type
1.0.0
|
Partial specialization. More...
#include <recursive_union.hpp>
Public Types | |
using | type = T |
The type of the value. | |
using | result_type = R |
The return type of visit | |
Static Public Member Functions | |
template<class... Fs> | |
static result_type | visit (recursive_union< type, Ts... > const &u, std::size_t i, Fs &&...fs) |
const overload (recursive_union<type, Ts...> const& ) | |
template<class... Fs> | |
static result_type | visit (recursive_union< T, Ts... > &u, std::size_t i, Fs &&...fs) |
non-const overload (recursive_union<type, Ts...>& ) | |
Partial specialization.
The role of this visitor is to "walk" the recursive union until the active type is reached. When it is, the form of visit that searches for the right closure to apply to the value there is invoked (see recurs //!
R | return type |
I | Head of an integer pack |
I | Tail of an integer pack |
T | Head of the parameter pack (of union types) |
Ts | Tail of the parameter pack (of union types) |
return type is R
, range<>
is non-empty. This specialization applies when the head of the parameter pack is not a reference_wrapper<>