From a6b5a6bdd138a5ccc6827bcc73580df1e9218820 Mon Sep 17 00:00:00 2001 From: Sébastien Dailly Date: Fri, 24 Nov 2017 09:22:24 +0100 Subject: Moved all the code to src directory --- UTF8.ml | 54 ------------------------------------------------------ 1 file changed, 54 deletions(-) delete mode 100755 UTF8.ml (limited to 'UTF8.ml') diff --git a/UTF8.ml b/UTF8.ml deleted file mode 100755 index a955b1e..0000000 --- a/UTF8.ml +++ /dev/null @@ -1,54 +0,0 @@ -include Text - -let empty = "" - -let decode x = Text.decode x - -let encode x = - try Some (Text.encode x) - with Text.Invalid (_, _) -> None - -let raw_encode x = Text.encode x - -let from_utf8string x = x - -let to_utf8string x = x - -let trim x = Text.strip x - -let split str ~sep = - match Text.split ~max:1 ~sep str with - | [] -> "" - | hd::tl -> hd - -let replace text patt repl = Text.replace text ~patt ~repl - -module Buffer = struct - - include Buffer - - type buffer = t - - let add_char b c = Uchar.of_char c - |> Uchar.to_int - |> Text.char - |> Buffer.add_string b -end - -module Printf = struct - - include Printf - -end - -module Format = struct - - include Format - - let bprintf buffer fformat = begin - let to_b = formatter_of_buffer buffer in - let x = fprintf to_b fformat in - x - end - -end -- cgit v1.2.3