OxL Reference

interface Eq

Types whose values can be compared with == (@derive(Eq)).

Example:

oxl✓ checked in CI
@derive(Eq)
data Point { x: i32; y: i32 }

fn main() io {
  print("{Point{ x: 1, y: 2 } == Point{ x: 1, y: 2 }} {Point{ x: 1, y: 2 } == Point{ x: 2, y: 2 }}")
}
Output
true false
pub(api) interface Eq

Since. 1.0.0-beta

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

See also