From a5e6b122015111ec08d4d3a88b905115bdff4735 Mon Sep 17 00:00:00 2001 From: Andrew Lygin Date: Thu, 19 May 2022 19:41:57 +0300 Subject: [PATCH 1/2] Fix links to macro rules in doc --- crossbeam-channel/src/channel.rs | 2 ++ crossbeam-channel/src/select.rs | 2 ++ crossbeam-channel/src/select_macro.rs | 2 +- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/crossbeam-channel/src/channel.rs b/crossbeam-channel/src/channel.rs index 27423b7e7..5196677a5 100644 --- a/crossbeam-channel/src/channel.rs +++ b/crossbeam-channel/src/channel.rs @@ -232,6 +232,8 @@ pub fn at(when: Instant) -> Receiver { /// # Examples /// /// Using a `never` channel to optionally add a timeout to [`select!`]: +/// +/// [`select!`]: crate::select! /// /// ``` /// use std::thread; diff --git a/crossbeam-channel/src/select.rs b/crossbeam-channel/src/select.rs index 710b61221..70e89067d 100644 --- a/crossbeam-channel/src/select.rs +++ b/crossbeam-channel/src/select.rs @@ -518,6 +518,8 @@ pub(crate) fn select_deadline<'a>( /// /// The [`select!`] macro is a convenience wrapper around `Select`. However, it cannot select over a /// dynamically created list of channel operations. +/// +/// [`select!`]: crate::select! /// /// Once a list of operations has been built with `Select`, there are two different ways of /// proceeding: diff --git a/crossbeam-channel/src/select_macro.rs b/crossbeam-channel/src/select_macro.rs index 0a609573e..efe0ae406 100644 --- a/crossbeam-channel/src/select_macro.rs +++ b/crossbeam-channel/src/select_macro.rs @@ -993,7 +993,7 @@ macro_rules! crossbeam_channel_internal { /// An operation is considered to be ready if it doesn't have to block. Note that it is ready even /// when it will simply return an error because the channel is disconnected. /// -/// The `select` macro is a convenience wrapper around [`Select`]. However, it cannot select over a +/// The `select!` macro is a convenience wrapper around [`Select`]. However, it cannot select over a /// dynamically created list of channel operations. /// /// [`Select`]: super::Select From 8eff2a458f606c479393181cec364cdb55d2b28f Mon Sep 17 00:00:00 2001 From: Andrew Lygin Date: Thu, 19 May 2022 19:53:35 +0300 Subject: [PATCH 2/2] Fix formatting --- crossbeam-channel/src/channel.rs | 2 +- crossbeam-channel/src/select.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crossbeam-channel/src/channel.rs b/crossbeam-channel/src/channel.rs index 5196677a5..800fe6352 100644 --- a/crossbeam-channel/src/channel.rs +++ b/crossbeam-channel/src/channel.rs @@ -232,7 +232,7 @@ pub fn at(when: Instant) -> Receiver { /// # Examples /// /// Using a `never` channel to optionally add a timeout to [`select!`]: -/// +/// /// [`select!`]: crate::select! /// /// ``` diff --git a/crossbeam-channel/src/select.rs b/crossbeam-channel/src/select.rs index 70e89067d..57d67a3a1 100644 --- a/crossbeam-channel/src/select.rs +++ b/crossbeam-channel/src/select.rs @@ -518,7 +518,7 @@ pub(crate) fn select_deadline<'a>( /// /// The [`select!`] macro is a convenience wrapper around `Select`. However, it cannot select over a /// dynamically created list of channel operations. -/// +/// /// [`select!`]: crate::select! /// /// Once a list of operations has been built with `Select`, there are two different ways of