diff --git a/library/std/src/sync/mpsc/mod.rs b/library/std/src/sync/mpsc/mod.rs index d23a8161a229c..dc13c9433f121 100644 --- a/library/std/src/sync/mpsc/mod.rs +++ b/library/std/src/sync/mpsc/mod.rs @@ -1532,7 +1532,9 @@ impl error::Error for TrySendError { #[stable(feature = "mpsc_error_conversions", since = "1.24.0")] impl From> for TrySendError { /// Converts a `SendError` into a `TrySendError`. + /// /// This conversion always returns a `TrySendError::Disconnected` containing the data in the `SendError`. + /// /// No data is allocated on the heap. fn from(err: SendError) -> TrySendError { match err { @@ -1580,7 +1582,9 @@ impl error::Error for TryRecvError { #[stable(feature = "mpsc_error_conversions", since = "1.24.0")] impl From for TryRecvError { /// Converts a `RecvError` into a `TryRecvError`. + /// /// This conversion always returns `TryRecvError::Disconnected`. + /// /// No data is allocated on the heap. fn from(err: RecvError) -> TryRecvError { match err { @@ -1613,7 +1617,9 @@ impl error::Error for RecvTimeoutError { #[stable(feature = "mpsc_error_conversions", since = "1.24.0")] impl From for RecvTimeoutError { /// Converts a `RecvError` into a `RecvTimeoutError`. + /// /// This conversion always returns `RecvTimeoutError::Disconnected`. + /// /// No data is allocated on the heap. fn from(err: RecvError) -> RecvTimeoutError { match err {