module Listutils: sig
.. end
Utility functions for list manipulation.
val push : 'a -> 'a list Pervasives.ref -> unit
push element listref
effects that element
is added to the beginning
of the list in listref
.
val pushnew : 'a -> 'a list Pervasives.ref -> unit
pushnew element listref
effects that element
is added to the beginning
of the list in listref
if it is not equal to a member of the list.
val pushnewq : 'a -> 'a list Pervasives.ref -> unit
Same as pushnew
, but physical equality is used to compare
list elements.
val sort_without_duplicates : 'a list -> 'a list
The result list is the input list, sorted by Pervasives.compare
and
with duplicate elements removed.