Struct std::WheelTimer
struct WheelTimer {
unsigned long expires;
?fn void(?&Erased) callback;
?&Erased ctx;
int used;
int periodic;
unsigned long period;
}Fields
absolute tick when the timer fires
One TimerWheel is a multi-tenant scheduler: its slots host timers with unrelated context types at once, so each slot stores its callback and context type-erased. They are only ever written by TimerWheel::add/add_periodic below, which take a matching fn void(?&T) / ?&T pair, so the erased call is always well-typed (see std/erased.h).
the fn void(?&T); null when free
the ?&T
1 if slot occupied, 0 if free
1 → auto-reschedule every period ticks
interval for periodic timers