std.datetime.date.DateTimeException if the new year is not a leap year and the resulting date would be on February 29th.
import std.datetime.date : DateTime; assert(SysTime(DateTime(1999, 7, 6, 9, 7, 5)).year == 1999); assert(SysTime(DateTime(2010, 10, 4, 0, 0, 30)).year == 2010); assert(SysTime(DateTime(-7, 4, 5, 7, 45, 2)).year == -7);
Year of the Gregorian Calendar. Positive numbers are A.D. Non-positive are B.C.