PosInfInterval.expand

void expand(D)(D duration) if (__traits(compiles, begin + duration)) pure nothrow

Expands the interval backwards in time. Effectively, it does

begin -= duration.

Parameters

durationThe duration to expand the interval by. Example: -------------------- auto interval1 = PosInfInterval!Date(Date(1996, 1, 2)); auto interval2 = PosInfInterval!Date(Date(1996, 1, 2)); interval1.expand(dur!"days"(2)); assert(interval1 == PosInfInterval!Date(Date(1995, 12, 31))); interval2.expand(dur!"days"(-2)); assert(interval2 == PosInfInterval!Date(Date(1996, 1, 4))); --------------------