big_set
Lazily accessed sets
type t<elt> = big_map<elt, unit>
The type of the big sets is based on big_map
.
let empty: <elt>t<elt>
let update: <elt>(_: elt) => (_: bool) => (_: t<elt>) => t<elt>
The call update(elt, true, set)
is a copy of the big set set
containing the element elt
. The call update(elt, false, set)
is a copy of the big set set
where the element elt
is
absent.
let add: <elt>(_: elt) => (_: t<elt>) => t<elt>
The call add(elt, set)
is a big set containing all the elements
of the big set set
, plus the element elt
.
let remove: <elt>(_: elt) => (_: t<elt>) => t<elt>
The call remove(elt, set)
is a copy of the set set
without the
element elt
.
let literal: <elt>(_: list<elt>) => t<elt>
The call literal(list([e1, ..., en]))
is a big set containing
exactly the elements in the list. Note: The list must be literal,
not an expression (compile-time list of values).
let of_list: <elt>(_: list<elt>) => t<elt>
The call of_list(elements)
is a big set containing exactly the
elements in the list elements
. Note: Use literal
instead if
using a literal list. Note: Use literal
instead if using a
literal list.
let mem: <elt>(_: elt) => (_: t<elt>) => bool
The call mem(elt, set)
is true
if, and only if, the element
elt
belongs to the big set set
.