module Ordset: sig .. end
Representation of sets as ordered list. This module is similar to the
ordsets library module common in Prolog systems.
Comparison using Pervasives.compare
val list_to_ord_set : 'a list -> 'a list
list_to_ord_set list returns an ordered set with the
elements of list, i.e. a copy of list with duplicate 'aents
removed.
val ord_insert : 'a list -> 'a -> 'a list
ord_insert set element returns a set with element inserted
into it, preserving the order. set is an ordered set.
val ord_union : 'a list -> 'a list -> 'a list
ord_union set1 set2 returns the ordered union of set1 and
set2. If both sets contain an element, it is retained only
once in the result. set1 and set1 are ordered sets.
val ord_intersection : 'a list -> 'a list -> 'a list
ord_intersection set1 set2 returns the ordered intersection of
set1 and set2. set1 and set1 are ordered sets.
val ord_subtract : 'a list -> 'a list -> 'a list
ord_subtract set1 set2 returns the elements in set1 which are not
also in set2 as ordered set. set1 and set1 are ordered sets.
val ord_symdiff : 'a list -> 'a list -> 'a list
ord_symdiff set1 set2 returns the symmetric difference
of set1 and set2 as ordered set. set1 and set1 are
ordered sets.
val ord_subset : 'a list -> 'a list -> bool
ord_subset set1 set2 is true iff every element of the ordered
set set1 appears in the ordered set set2.
set1 and set1 are ordered sets.
val ord_disjoint : 'a list -> 'a list -> bool
ord_disjoint set1 set2 is true iff set1 and set2 have no
elements in common. set1 and set1 are ordered sets.
val ord_intersect : 'a list -> 'a list -> bool
ord_intersect set1 set2 is true iff set1 and set2 have
at least one element in common. set1 and set1 are ordered sets.
Functorial Interface
module type AuxOrderedType = sig .. end
Input signature of the MakeAux functor.
module type AuxS = sig .. end
Output signature of the MakeAux functor.
module MakeAux:
Functor building an implementation of the Ordset.AuxS type
given a totally ordered type.