StructFromParams

Undocumented in source.
static if(haveStaticForeach)
struct StructFromParams (
alias fun
bool voidInitializeRequired = false
)

Examples

Generates a struct containing fields with names, types, and default values corresponding to a function's parameter list.

static void fun(string a, int b = 42) {}
alias S = StructFromParams!fun;
static assert(is(typeof(S.a) == string));
static assert(S.init.b == 42);

Meta