home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Source Code / C / Applications / Moscow ML 1.31 / source code / mosml / src / mosmllib / Byte.sml < prev    next >
Encoding:
Text File  |  1996-07-03  |  438 b   |  16 lines  |  [TEXT/R*ch]

  1. (* Byte *)
  2.  
  3. exception Ord = Ord;        (* Not raised by these functions *)
  4.  
  5. local 
  6.     prim_val chr_    : Word8.word -> Char.char      = 1 "identity";
  7.     prim_val ord_    : Char.char -> Word8.word      = 1 "identity";
  8.     prim_val string_ : Word8Vector.vector -> string = 1 "identity";
  9. in
  10.     val chr = chr_;
  11.     val ord = ord_;
  12.     val string = string_;
  13.     fun extract (a, i, sliceend) = 
  14.     string (Word8Array.extract (a, i, sliceend));
  15. end
  16.