package ppx_rapper
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=d6ce377b4a0d8c1c8f9fefd643c35282
sha512=16cdb7bc4632ebbd77cbed26c1852ad38274c7ae2dd7b3455c6671f3579137f5598fa044b80272457ef859cf79831b087c63de13252630d85b0b8ff4dcfd2125
doc/ppx_rapper.runtime/Rapper/Make_helper/argument-1-Io/Stream/index.html
Module Io.Stream
and ('a, 'err) node = | Nil(*The node of an empty stream
*)| Error of 'err(*A node of a permanently failed stream.
*)| Cons of 'a * ('a, 'err) t(*A node holding the next element and continuation of a stream.
*)
fold ~f stream acc consumes the remainder elements e1, ..., eN of stream and returns Ok (acc |> f e1 |> ... |> f eN) if no error occurred
val fold_s :
f:('a -> 'state -> ('state, 'err) result t) ->
('a, 'clog) t ->
'state ->
('state, [> `Congested of 'clog ] as 'err) result tfold_s ~f stream acc consumes the remainder of stream, passing each element in order to f along with the latest accumulation starting at acc, and returning the final accumulation if successful. An error result may be due to either the stream provider or the callback, as distinguished with the `Congested constructor.
val iter_s :
f:('a -> (unit, 'err) result t) ->
('a, 'clog) t ->
(unit, [> `Congested of 'clog ] as 'err) result titer_s ~f stream consumes the remainder of stream, passing each element in order to f. An error result may be due to either the steram provider or the callback, as distinguished with the `Congested constructor.
to_rev_list stream consumes the remainder of stream, returning a list of its element in reverse order of production.
to_list stream consumes the remainder of stream, returning a list of its element in order of production.
val of_list : 'a list -> ('a, 'err) tof_list xs is a non-failing finite stream (re)producing the elements xs in order of occurrence.