interface Hash
Types that can be keys of a Map or elements of a Set (@derive(Eq, Hash)).
Example:
@derive(Eq, Hash)
data Cell { row: i32; col: i32 }
fn main() io {
var visited: Set<Cell> = Set.new()
visited.insert(Cell{ row: 1, col: 2 })
print("{visited.contains(Cell{ row: 1, col: 2 })} {visited.contains(Cell{ row: 2, col: 1 })}")
}Output
true false
pub(api) interface HashSince. 1.0.0-beta
Defined in: std/core/types.oxl:883