From ba5f590acda40cccbc8dd3e942ff227b3978ac26 Mon Sep 17 00:00:00 2001 From: Jonas Platte Date: Fri, 25 Oct 2024 00:55:07 +0200 Subject: [PATCH] Document 'async fn' notation for boardcast::Receiver::recv --- tokio/src/sync/broadcast.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tokio/src/sync/broadcast.rs b/tokio/src/sync/broadcast.rs index 887080199..2e3f9689c 100644 --- a/tokio/src/sync/broadcast.rs +++ b/tokio/src/sync/broadcast.rs @@ -1215,6 +1215,12 @@ impl Receiver { } /// Receives the next value for this receiver. /// + /// Equivalent to: + /// + /// ```ignore + /// async fn recv(&self) -> Result; + /// ``` + /// /// Each [`Receiver`] handle will receive a clone of all values sent /// **after** it has subscribed. ///