alice
library
manual.

Alice Project

The ORDERED signature


________ Synopsis ____________________________________________________

    signature ORDERED
  

An abstract signature for types that provide an ordering, useful for functor arguments. Note that most basic types in the fundamental library match this signature.

See also: HASHABLE


________ Import ______________________________________________________

    import signature ORDERED from "x-alice:/lib/data/ORDERED-sig"

________ Interface ___________________________________________________

    signature ORDERED =
    sig
	type t

	val compare :  t * t -> order
    end
  

________ Description _________________________________________________

type t

The abstract type of ordered values.

compare (x1, x2)

Returns the relative order of x1 and x2. May raise Unordered if both values are incomparable in a partial ordering.



last modified 2007/Mar/30 17:10