Converts the template parameters into a type_list. More...
#include <ugmisc/typelist.hpp>
Public Types | |
| using | type = concatenate_type_lists_t<typename flatten<T>::type...> |
Converts the template parameters into a type_list.
Every parameter which is itself a type_list is unrolled. Every wrapped_list is unwrapped (but not recursively).
So for example:
flatten_t< typelist<A, B>, C, wrapped_list<typelist<D, E, F> >
is the type:
typelist<A, B, C, typelist<D, E, F> >
The implementation uses some single-arg template specializations to distinguish between template args which are type_list, wrapped_list, or neither. Then the non-specialised flatten concatenates the types produced by those.
A wrapped_list should be unwrapped once, whereas a type_list should be unwrapped recursively.