From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id GAA25803; Mon, 4 Nov 2002 06:16:47 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id GAA25491 for ; Mon, 4 Nov 2002 06:16:46 +0100 (MET) X-SPAM-Warning: Sending machine is listed in blackholes.five-ten-sg.com Received: from climbxp ([159.226.149.121]) by concorde.inria.fr (8.11.1/8.11.1) with SMTP id gA45Gh504019 for ; Mon, 4 Nov 2002 06:16:44 +0100 (MET) Message-Id: <200211040516.gA45Gh504019@concorde.inria.fr> From: "climb" To: "caml-list@inria.fr" Subject: [Caml-list] how to open the type X-mailer: Foxmail 4.2 [cn] Mime-Version: 1.0 Content-Type: text/plain; charset="GB2312" Content-Transfer-Encoding: 7bit Date: Mon, 4 Nov 2002 13:17:4 +0800 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk I want to use hashtable on my objects which all has a method get_string:string. but i can only write the code like these: module SeqHashType = struct type t= let equal s1 s2 = (String.uppercase s1#get_string =String.uppercase s2#get_string ) let hash s = Strex.hash s#get_string end module SeqHashtbl = Hashtbl.Make (SeqHashType) surely it is not what i want . i have tried type t= but i can not complie it , the complier says Unbound .. then how to open the type in the module SeqHashType ? or it can not be opened at this situation ? i am a newbie and a little puzzled at open types. Best regards Yours climb onlyclimb@163.com 2002-11-03 ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners