Skip to main content

plan

Function plan 

Source
fn plan(now: Instant, next: Option<Instant>, slice: Duration) -> Wait
Expand description

Decide the next wait from a clock reading and the head of the heap.

Never returns a Sleep that runs past next: that, plus the slot.at <= now re-check in run, is the whole never-fire-early guarantee.