fn duration_seconds(ms: i64) -> f64
Go’s time.Duration.Seconds of ms milliseconds: whole seconds plus the remainder over 1e9, two roundings rather than one division. The nanosecond count saturates as time.Time.Sub does.
time.Duration.Seconds
ms
time.Time.Sub