The OpenD Programming Language

enumStrings

Aliases itself to enumMembers for string enums and enumIdentifiers for integral and floating point enums.

template enumStrings (
T
) if (
is(T == enum)
) {}

Examples

enum E {z = 1, b = -1, c}
static assert(enumStrings!E == ["z", "b", "c"]);

enum S {a = "A", b = "B", c = ""}
static assert(enumStrings!S == [S.a, S.b, S.c]);

Meta