A type.
$(D_KEYWORD true) if R is an infinite range, $(D_KEYWORD false) otherwise.
static assert(!isInfinite!int); static struct NotRange { enum bool empty = false; } static assert(!isInfinite!NotRange); static struct InfiniteRange { void popFront() @nogc nothrow pure @safe { } @property int front() @nogc nothrow pure @safe { return 0; } enum bool empty = false; } static assert(isInfinite!InfiniteRange); static struct InputRange { void popFront() @nogc nothrow pure @safe { } @property int front() @nogc nothrow pure @safe { return 0; } @property bool empty() const @nogc nothrow pure @safe { return false; } } static assert(!isInfinite!InputRange);
Determines whether R is an infinite range.
An infinite range is an input range whose empty member is defined as $(D_KEYWORD enum) which is always $(D_KEYWORD false).