Expand description
Seconds that arrive as a float, as a Duration.
A wait, a window, an interval or a token’s lifetime reaches every surface as a number of
seconds: a CLI flag, a keyword argument, a JSON field. of_secs_f64 is the conversion all
of them call, so a figure that can’t be a duration is refused before any work starts, with
one message everywhere (#268). A figure bound for a cost report goes through
crate::cost::duration_of_secs_f64 instead, whose refusal also says why a negative span
matters there; a wait has no report to put a credit on, so its refusal doesn’t claim one
(#338).
Functions§
- of_
secs_ f64 - Seconds from a float, refused when the float can’t be a duration.