diff --git a/tokio/src/sync/mpsc/error.rs b/tokio/src/sync/mpsc/error.rs index 9fef7fd9c03..cd087af5886 100644 --- a/tokio/src/sync/mpsc/error.rs +++ b/tokio/src/sync/mpsc/error.rs @@ -3,7 +3,7 @@ use std::error::Error; use std::fmt; -/// Error returned by the `Sender`. +/// Error returned by [`Sender::send`](super::Sender::send). #[derive(PartialEq, Eq, Clone, Copy)] pub struct SendError(pub T); @@ -23,8 +23,7 @@ impl Error for SendError {} // ===== TrySendError ===== -/// This enumeration is the list of the possible error outcomes for the -/// [`try_send`](super::Sender::try_send) method. +/// Error returned by [`Sender::try_send`](super::Sender::try_send). #[derive(PartialEq, Eq, Clone, Copy)] pub enum TrySendError { /// The data could not be sent on the channel because the channel is @@ -78,7 +77,7 @@ impl From> for TrySendError { // ===== TryRecvError ===== -/// Error returned by `try_recv`. +/// Error returned by [`Receiver::try_recv`](super::Receiver::try_recv). #[derive(PartialEq, Eq, Clone, Copy, Debug)] pub enum TryRecvError { /// This **channel** is currently empty, but the **Sender**(s) have not yet @@ -122,7 +121,7 @@ cfg_time! { // ===== SendTimeoutError ===== #[derive(PartialEq, Eq, Clone, Copy)] - /// Error returned by [`Sender::send_timeout`](super::Sender::send_timeout)]. + /// Error returned by [`Sender::send_timeout`](super::Sender::send_timeout). pub enum SendTimeoutError { /// The data could not be sent on the channel because the channel is /// full, and the timeout to send has elapsed.