home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / C / Applications / Moscow ML 1.42 / lib / Misc.sig < prev    next >
Encoding:
Text File  |  1997-08-18  |  1.1 KB  |  40 lines  |  [TEXT/Moml]

  1. (* Misc 1997-01-29 *)
  2.  
  3. (* These functions really belong in General, but can appear there only 
  4.    if defined in the runtime system.  So for now they are here.
  5.  *)
  6.  
  7. type 'a array  = 'a Array.array
  8.  
  9. val o : ('b -> 'c) * ('a -> 'b) -> 'a -> 'c
  10. val before : ('a * unit) -> 'a
  11.  
  12. val chr : int -> char
  13. val ord : char -> int
  14.  
  15. val explode : string -> char list
  16. val implode : char list -> string
  17. val str     : char -> string
  18. val concat  : string list -> string
  19.  
  20. val vector  : 'a list -> 'a vector
  21.  
  22. val getOpt  : 'a option * 'a -> 'a
  23. val isSome  : 'a option -> bool
  24. val valOf   : 'a option -> 'a      
  25.  
  26. exception Empty;
  27.  
  28. val @       : 'a list * 'a list -> 'a list
  29. val app     : ('a -> unit) -> 'a list -> unit
  30. val foldl   : ('a * 'b -> 'b) -> 'b -> 'a list -> 'b
  31. val foldr   : ('a * 'b -> 'b) -> 'b -> 'a list -> 'b
  32. val hd      : 'a list -> 'a                     (* Empty     *)
  33. val length  : 'a list -> int 
  34. val map     : ('a -> 'b) -> 'a list -> 'b list
  35. val null    : 'a list -> bool
  36. val rev     : 'a list -> 'a list 
  37. val tl      : 'a list -> 'a list                (* Empty     *)
  38.  
  39. val print   : string -> unit
  40.