From 0b2e63791a073000b70b4463db5d8bce88ab4d23 Mon Sep 17 00:00:00 2001 From: Sébastien Dailly Date: Sat, 4 Sep 2021 09:42:31 +0200 Subject: Update --- src/lib/repr/default.ml | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/lib/repr/default.ml') diff --git a/src/lib/repr/default.ml b/src/lib/repr/default.ml index 72cf95d..e8cc091 100644 --- a/src/lib/repr/default.ml +++ b/src/lib/repr/default.ml @@ -1,3 +1,5 @@ +open StdLabels + type t = string let none = "" @@ -56,3 +58,11 @@ let diphtongue : t -> t -> t = fun t1 t2 -> Printf.sprintf "[%s%s]" t1 t2 + +let fold + : t list -> string + = fun elems -> + let buff = Buffer.create 16 in + List.iter elems + ~f:(fun f -> Buffer.add_string buff f); + Buffer.contents buff -- cgit v1.2.3