Measure the weekday, and record why Hinnant's stays
Ben Joffe's article on weekdays offers a 64-bit multiply-add-shift: the low 64 bits of days * ceil(2^64 / 7), turned round to Thursday, top three bits. It agreed with DayOfWeek.fromDaysSinceStartOfEra on 200 million day numbers and is exact far past the range of DaysType. It ran at 3.3 ns against 4.1 with chained calls and 0.68 against 0.77 with independent ones. Instant.asDateTime and the TimeZone lookups that call it showed no difference, so the doc comment records the comparison and the code is unchanged. zig build bench gains DayOfWeek.fromDays, measured with independent and with chained calls, and its name column widens to fit. The README cites the article. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Ub7C4SHwzbWTUR2TA4eGgR