Searched refs:is_leap (Results 1 – 5 of 5) sorted by relevance
28 ASSERT_NOEXCEPT( year(1).is_leap()); in main()29 ASSERT_SAME_TYPE(bool, decltype(year(1).is_leap())); in main()31 static_assert(!year{1}.is_leap(), ""); in main()32 static_assert(!year{2}.is_leap(), ""); in main()33 static_assert(!year{3}.is_leap(), ""); in main()34 static_assert( year{4}.is_leap(), ""); in main()36 assert( year{-2000}.is_leap()); in main()37 assert( year{ -400}.is_leap()); in main()38 assert(!year{ -300}.is_leap()); in main()39 assert(!year{ -200}.is_leap()); in main()[all …]
124 bool is_leap = (!yd1 || yd2) && !yd3; in YearMonthDayFromDays() local127 DCHECK(is_leap || (days >= 0)); in YearMonthDayFromDays()128 DCHECK((days < 365) || (is_leap && (days < 366))); in YearMonthDayFromDays()129 DCHECK(is_leap == ((*year % 4 == 0) && (*year % 100 || (*year % 400 == 0)))); in YearMonthDayFromDays()130 DCHECK(is_leap || ((DaysFromYearMonth(*year, 0) + days) == save_days)); in YearMonthDayFromDays()131 DCHECK(!is_leap || ((DaysFromYearMonth(*year, 0) + days + 1) == save_days)); in YearMonthDayFromDays()133 days += is_leap; in YearMonthDayFromDays()136 if (days >= 31 + 28 + BoolToInt(is_leap)) { in YearMonthDayFromDays()137 days -= 31 + 28 + BoolToInt(is_leap); in YearMonthDayFromDays()
177 is_leap(int year) in is_leap() function194 if (month == 2 && is_leap(year)) in days_in_month()209 if (month > 2 && is_leap(year)) in days_before_month()311 assert(leapyear == is_leap(*year)); in ord_to_ymd()
205 is_leap(int year) in is_leap() function222 if (month == 2 && is_leap(year)) in days_in_month()237 if (month > 2 && is_leap(year)) in days_before_month()333 assert(leapyear == is_leap(*year)); in ord_to_ymd()
1762 …inline constexpr bool is_leap() const noexcept { return __y % 4 == 0 && (__y % 100 != 0 || __y % 4…2440 return month() != February || !__y.is_leap() ?