Import Upstream version 20180207
[hcoop/debian/mlton.git] / lib / mlton / basic / relation.sig
CommitLineData
7f918cf1
CE
1(* Copyright (C) 1999-2005 Henry Cejtin, Matthew Fluet, Suresh
2 * Jagannathan, and Stephen Weeks.
3 *
4 * MLton is released under a BSD-style license.
5 * See the file MLton-LICENSE for details.
6 *)
7
8signature RELATION =
9 sig
10 datatype t = datatype order (* from the pervasive environment *)
11
12 val compare: ('a * 'a -> t)
13 -> {equals: 'a * 'a -> bool,
14 < : 'a * 'a -> bool,
15 > : 'a * 'a -> bool,
16 >= : 'a * 'a -> bool,
17 <= : 'a * 'a -> bool,
18 min: 'a * 'a -> 'a,
19 max: 'a * 'a -> 'a}
20 val equals: t * t -> bool
21 val layout: t -> Layout.t
22 val lexico: t * (unit -> t) -> t
23 val lessEqual: {< : 'a * 'a -> bool,
24 equals: 'a * 'a -> bool}
25 -> {> : 'a * 'a -> bool,
26 >= : 'a * 'a -> bool,
27 <= : 'a * 'a -> bool,
28 min: 'a * 'a -> 'a,
29 max: 'a * 'a -> 'a,
30 compare: 'a * 'a -> t}
31 end