isNullTestable

Returns true of T can be check with null using an if statement

template isNullTestable (
T...
) if (
T.length == 1
) {}

Members

Aliases

U
alias U = from.bolts.traits.symbols.TypesOf!T[0]
Undocumented in source.

Manifest constants

isNullTestable
enum isNullTestable;
Undocumented in source.

Examples

class C {}
struct S1 {
    void opAssign(int*) {}
}
static assert(!isNullTestable!S1);
static assert( isNullTestable!C);
static assert( isNullTestable!(int*));

struct S2 {}
static assert(!isNullTestable!S2);
static assert(!isNullTestable!int);

class C2 {
    @disable this();
}
static assert(isNullTestable!C2);

Meta