isLiteralOf

Checks if an alias is a literal of some type

template isLiteralOf (
ab...
) if (
ab.length == 2
) {}

Members

Manifest constants

isLiteralOf
enum isLiteralOf;
Undocumented in source.

Examples

static assert( isLiteralOf!("hi", string));
static assert(!isLiteralOf!(3, string));
static assert( isLiteralOf!(3, int));

int a;
static assert(!isLiteralOf!(a, int));

void f() {}
static assert(!isLiteralOf!(f, string));

Meta