Lines Matching refs:days

54     int days, int* year, int* month, int* day) {  in YearMonthDayFromDays()  argument
58 int new_day = ymd_day_ + (days - ymd_days_); in YearMonthDayFromDays()
61 ymd_days_ = days; in YearMonthDayFromDays()
68 int save_days = days; in YearMonthDayFromDays()
70 days += kDaysOffset; in YearMonthDayFromDays()
71 *year = 400 * (days / kDaysIn400Years) - kYearsOffset; in YearMonthDayFromDays()
72 days %= kDaysIn400Years; in YearMonthDayFromDays()
74 DCHECK_EQ(save_days, DaysFromYearMonth(*year, 0) + days); in YearMonthDayFromDays()
76 days--; in YearMonthDayFromDays()
77 int yd1 = days / kDaysIn100Years; in YearMonthDayFromDays()
78 days %= kDaysIn100Years; in YearMonthDayFromDays()
81 days++; in YearMonthDayFromDays()
82 int yd2 = days / kDaysIn4Years; in YearMonthDayFromDays()
83 days %= kDaysIn4Years; in YearMonthDayFromDays()
86 days--; in YearMonthDayFromDays()
87 int yd3 = days / 365; in YearMonthDayFromDays()
88 days %= 365; in YearMonthDayFromDays()
94 DCHECK(days >= -1); in YearMonthDayFromDays()
95 DCHECK(is_leap || (days >= 0)); in YearMonthDayFromDays()
96 DCHECK((days < 365) || (is_leap && (days < 366))); in YearMonthDayFromDays()
98 DCHECK(is_leap || ((DaysFromYearMonth(*year, 0) + days) == save_days)); in YearMonthDayFromDays()
99 DCHECK(!is_leap || ((DaysFromYearMonth(*year, 0) + days + 1) == save_days)); in YearMonthDayFromDays()
101 days += is_leap; in YearMonthDayFromDays()
104 if (days >= 31 + 28 + BoolToInt(is_leap)) { in YearMonthDayFromDays()
105 days -= 31 + 28 + BoolToInt(is_leap); in YearMonthDayFromDays()
108 if (days < kDaysInMonths[i]) { in YearMonthDayFromDays()
110 *day = days + 1; in YearMonthDayFromDays()
113 days -= kDaysInMonths[i]; in YearMonthDayFromDays()
117 if (days < 31) { in YearMonthDayFromDays()
119 *day = days + 1; in YearMonthDayFromDays()
122 *day = days - 31 + 1; in YearMonthDayFromDays()
181 int const days = DaysFromTime(time_ms); in BreakDownTime() local
182 int const time_in_day_ms = TimeInDay(time_ms, days); in BreakDownTime()
183 YearMonthDayFromDays(days, year, month, day); in BreakDownTime()
184 *weekday = Weekday(days); in BreakDownTime()