From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA04356 for caml-red; Fri, 30 Jun 2000 17:34:56 +0200 (MET DST) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id LAA25537 for ; Fri, 30 Jun 2000 11:22:54 +0200 (MET DST) Received: from julie.univ-savoie.fr (univax.univ-savoie.fr [193.48.120.32]) by nez-perce.inria.fr (8.10.0/8.10.0) with ESMTP id e5U9MpP04878 for ; Fri, 30 Jun 2000 11:22:52 +0200 (MET DST) Received: from univ-savoie.fr (lama-d134.univ-savoie.fr [193.48.123.134]) by julie.univ-savoie.fr (8.9.3/jtpda-5.3.3) with ESMTP id LAA51931 for ; Fri, 30 Jun 2000 11:22:49 +0200 (CEST) Message-ID: <395C66EA.645DA1F8@univ-savoie.fr> Date: Fri, 30 Jun 2000 11:22:50 +0200 From: Christophe Raffalli Organization: Laboratoire de =?iso-8859-1?Q?Math=E9matiques?=, =?iso-8859-1?Q?Universit=E9?= de Savoie X-Mailer: Mozilla 4.7 [fr] (X11; I; Linux 2.2.14-15mdksmp i686) X-Accept-Language: fr, en MIME-Version: 1.0 CC: caml-list@inria.fr Subject: Re: convenient features References: <200006291657.SAA11050@pauillac.inria.fr> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Sender: weis@pauillac.inria.fr I have a problem to define a type ! Whe I want is the following (which is incorrect !) (* index in a sequence *) type index = { index_key : int; mutable index_val : index_val } and index_val = Noval of index list | Hasval of index * IndexSet.t and module Index = struct type t = index let compare i j = i.index_key - j.index_key end and module IndexSet = Set.Make(Index) Does someone see a solution ? ( I have a soliution using Obj.t ... But it is not reasonnable) -- Christophe Raffalli Université de Savoie Batiment Le Chablais, bureau 21 73376 Le Bourget-du-Lac Cedex tél: (33) 4 79 75 81 03 fax: (33) 4 79 75 87 42 mail: Christophe.Raffalli@univ-savoie.fr www: http://www.lama.univ-savoie.fr/~RAFFALLI