1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
|
type comparison =
| Eq
| Lt
| Gt
type char63 = Uint63.t
type string = Pstring.t
(** val make : Uint63.t -> char63 -> string **)
let make = Pstring.make
(** val length : string -> Uint63.t **)
let length = Pstring.length
(** val sub : string -> Uint63.t -> Uint63.t -> string **)
let sub = Pstring.sub
(** val cat : string -> string -> string **)
let cat = Pstring.cat
(** val compare : string -> string -> comparison **)
let compare = (fun x y -> let c = Pstring.compare x y in if c = 0 then Eq else if c < 0 then Lt else Gt)
(** val s1 : string **)
let s1 =
(Pstring.unsafe_of_string "hello")
(** val s2 : string **)
let s2 =
(Pstring.unsafe_of_string "wwworlddd")
(** val s : string **)
let s =
cat s1
(cat (Pstring.unsafe_of_string ", ")
(cat (sub s2 (Uint63.of_int (2)) (Uint63.of_int (5)))
(Pstring.unsafe_of_string "!")))
(** val w : string **)
let w =
make (length s) (Uint63.of_int (119))
(** val c : comparison **)
let c =
compare s w
|