There's an _is_ expression, which allows one to determine the
underlying type of a enum:

template EnumType(T)
    if(is(T U = enum))
{
    alias U EnumType;
}

It would be awesome if the same mechanism was implemented for aliased types:

template AliasType(T)
    if(is(T U = alias))
{
    enum string AliasType = U;
}

which would return a string, containing the alias name.

Reply via email to