OxL Reference

method Inst.now

Monotonic clock reading (§17.3).

Example:

oxl✓ checked in CI
use std.time { Instant }

fn main() io, time {
  let t0 = Instant.now()
  let spent = t0.elapsed()
  print("{spent.isNegative()}")
}
Output
false
pub(api) static fn now() -> Inst  time

Since. 1.0.0-beta

Returns

Inst

Effects

time

Defined in: std/time/time.oxl:2040

See also