mostNegative

Returns the minimum value of type T. In contrast to T.min this template works with floating point and complex types as well.

Members

Variables

mostNegative
enum T mostNegative;
Undocumented in source.
mostNegative
enum T mostNegative;
Undocumented in source.

Parameters

T

Integral, boolean, floating point, complex or character type.

Return Value

The minimum value of T.

Examples

static assert(mostNegative!char == char.min);
static assert(mostNegative!wchar == wchar.min);
static assert(mostNegative!dchar == dchar.min);

static assert(mostNegative!byte == byte.min);
static assert(mostNegative!ubyte == ubyte.min);
static assert(mostNegative!bool == bool.min);

static assert(mostNegative!float == -float.max);
static assert(mostNegative!double == -double.max);
static assert(mostNegative!real == -real.max);

static assert(mostNegative!ifloat == -ifloat.max);
static assert(mostNegative!cfloat == -cfloat.max);

See Also

$(D_PSYMBOL isIntegral), $(D_PSYMBOL isBoolean), $(D_PSYMBOL isSomeChar), $(D_PSYMBOL isFloatingPoint), $(D_PSYMBOL isComplex).

Meta