From 0c8f92a24ce0e4d6e954b70e29c89ec874592bc5 Mon Sep 17 00:00:00 2001 From: Clombrong Date: Tue, 17 Jun 2025 20:55:59 +0200 Subject: docs(stream): docstring get wrapper --- lib/stream.ml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/stream.ml b/lib/stream.ml index 677b60d..b26d02f 100644 --- a/lib/stream.ml +++ b/lib/stream.ml @@ -4,6 +4,9 @@ exception ClosedStream exception InvalidStanza of string let get stream = + (** [get stream] returns a promise containing an element of [stream]. + + If [stream] is closed, it throws a ClosedStream Lwt exception. *) let* stanza = Lwt_stream.get stream in match stanza with | Some stanza -> Lwt.return stanza -- cgit v1.2.3