[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Vincent Barichard <Vincent Barichard <Vincent.Barichard@i...> |
| Subject: | [Caml-list] Polymorphic Set |
Hi,
Is there a way in OCAML to create polymorphic Set (as for List) ?
I've tried the following code, but ocaml don't like.
module MySet = Set.Make (struct
type t = ('a * float)
let compare = function (_, valx) -> function (_, valy) ->
if valx < valy then 1
else if valx > valy then -1
else 0
end)
Anybody has an idea on how to do ?
Thanks for your help,
Vincent
--
Vincent Barichard
Métaheuristiques et Optimisation Combinatoire
Faculté des Sciences d'Angers
Tel : 02 41 73 52 06
-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr