caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] how to open the type
@ 2002-11-03 14:34 climb
  0 siblings, 0 replies; 4+ messages in thread
From: climb @ 2002-11-03 14:34 UTC (permalink / raw)
  To: caml-list

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= <get_string:string >
  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= <get_string:string ; ..>

but i can not complie it , the complier says Unbound ..
then how to open the type <get_string:string> 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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Caml-list] how to open the type
@ 2002-11-04  8:00 climb
  0 siblings, 0 replies; 4+ messages in thread
From: climb @ 2002-11-04  8:00 UTC (permalink / raw)
  To: caml-list

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= <get_string:string >
  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= <get_string:string ; ..>

but i can not complie it , the complier says Unbound ..
then how to open the type <get_string:string> 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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Caml-list] how to open the type
@ 2002-11-04  5:17 climb
  0 siblings, 0 replies; 4+ messages in thread
From: climb @ 2002-11-04  5:17 UTC (permalink / raw)
  To: caml-list

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= <get_string:string >
  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= <get_string:string ; ..>

but i can not complie it , the complier says Unbound ..
then how to open the type <get_string:string> 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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Caml-list] how to open the type
@ 2002-11-03 13:28 climb
  0 siblings, 0 replies; 4+ messages in thread
From: climb @ 2002-11-03 13:28 UTC (permalink / raw)
  To: caml-list

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= <get_string:string >
  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= <get_string:string ; ..>

but i can not complie it , the complier says Unbound ..
then how to open the type <get_string:string> 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


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-11-04  7:59 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-03 14:34 [Caml-list] how to open the type climb
  -- strict thread matches above, loose matches on Subject: below --
2002-11-04  8:00 climb
2002-11-04  5:17 climb
2002-11-03 13:28 climb

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).