package containers

  1. Overview
  2. Docs
val add : ?eq:('a -> 'a -> bool) -> 'a -> 'a t -> 'a t

add x set adds x to set if it was not already present

  • since 0.11
val remove : ?eq:('a -> 'a -> bool) -> 'a -> 'a t -> 'a t

remove x set removes one occurrence of x from set

  • since 0.11
val mem : ?eq:('a -> 'a -> bool) -> 'a -> 'a t -> bool

membership to the list

val subset : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t -> bool

test for inclusion

val uniq : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t

list uniq: remove duplicates w.r.t the equality predicate

val union : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t -> 'a t

list union

val inter : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t -> 'a t

list intersection

OCaml

Innovation. Community. Security.