From 363c3b45288dc6a229f5f7a2878059ecd71f5e0e Mon Sep 17 00:00:00 2001 From: Fardale Date: Thu, 20 Dec 2018 01:04:11 +0100 Subject: [PATCH] [CCResult] add doc for map_l --- src/core/CCResult.mli | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/core/CCResult.mli b/src/core/CCResult.mli index a5b47bb6..04a69a5c 100644 --- a/src/core/CCResult.mli +++ b/src/core/CCResult.mli @@ -188,6 +188,9 @@ end (** {2 Collections} *) val map_l : ('a -> ('b, 'err) t) -> 'a list -> ('b list, 'err) t +(** [map_l f l] apply [f] on every element of [l], and, in case of success for every + element, return [Ok (List.map f l)]. Otherwise, it fails, and the first error is + return.*) val fold_l : ('b -> 'a -> ('b, 'err) t) -> 'b -> 'a list -> ('b, 'err) t