OxL Reference

data Instant

Monotonic clock reading, for measurements only (§17.1).

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
@builtin("Instant") pub(api) data Instant

Thread safety. an immutable value; readings of different tasks are comparable.

Since. 1.0.0-beta

Defined in: std/core/types.oxl:131

See also