Merge pull request #4579 from khaneliman/freebsd

fix(clock): fix freebsd compatibility
This commit is contained in:
Alexis Rouillard 2025-10-23 09:36:19 +02:00 committed by GitHub
commit 161367d961
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -230,7 +230,7 @@ const unsigned cldRowsInMonth(const year_month& ym, const weekday& firstdow) {
auto cldGetWeekForLine(const year_month& ym, const weekday& firstdow, const unsigned line) auto cldGetWeekForLine(const year_month& ym, const weekday& firstdow, const unsigned line)
-> const year_month_weekday { -> const year_month_weekday {
const unsigned idx = line - 2; const unsigned idx = line - 2;
const std::chrono::weekday_indexed indexed_first_day_of_week = const auto indexed_first_day_of_week =
weekday{ym / 1} == firstdow ? firstdow[idx + 1] : firstdow[idx]; weekday{ym / 1} == firstdow ? firstdow[idx + 1] : firstdow[idx];
return ym / indexed_first_day_of_week; return ym / indexed_first_day_of_week;