Skip to content

Commit

Permalink
channel doc: Fix misleading reference to None return on Receiver
Browse files Browse the repository at this point in the history
Signed-off-by: Jonathas-Conceicao <jonathas.conceicao@ossystems.com.br>
  • Loading branch information
Jonathas-Conceicao committed Jul 13, 2020
1 parent c82b1ef commit cd7fb9d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/sync/channel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ use crate::sync::WakerSet;
/// This channel has a buffer that can hold at most `cap` messages at a time.
///
/// Senders and receivers can be cloned. When all senders associated with a channel get dropped, it
/// becomes closed. Receive operations on a closed and empty channel return `None` instead of
/// trying to await a message.
/// becomes closed. Receive operations on a closed and empty channel return [RecvError] instead of
/// trying to await a message when using [Receiver::recv] or `None` when used as a [Stream].
///
/// # Panics
///
Expand Down Expand Up @@ -376,7 +376,7 @@ impl<T> Receiver<T> {
///
/// If the channel is empty and still has senders, this method
/// will wait until a message is sent into it. Once all senders
/// have been dropped it will return `None`.
/// have been dropped it will return [RecvError].
///
/// # Examples
///
Expand Down

0 comments on commit cd7fb9d

Please sign in to comment.