Merge pull request #23 from frewsxcv/docs

Add links in docs to `channel` function.
This commit is contained in:
Alex Crichton
2016-09-08 07:35:49 -07:00
committed by GitHub
+7 -3
View File
@@ -17,7 +17,9 @@ use reactor::{Handle, PollEvented};
/// A `Sender` can be `clone`d to have multiple threads or instances sending /// A `Sender` can be `clone`d to have multiple threads or instances sending
/// messages to one receiver. /// messages to one receiver.
/// ///
/// This type is created by the `channel` function. /// This type is created by the [`channel`] function.
///
/// [`channel`]: fn.channel.html
pub struct Sender<T> { pub struct Sender<T> {
tx: channel::Sender<T>, tx: channel::Sender<T>,
} }
@@ -28,8 +30,10 @@ pub struct Sender<T> {
/// A `Receiver` cannot be cloned, so only one thread can receive messages at a /// A `Receiver` cannot be cloned, so only one thread can receive messages at a
/// time. /// time.
/// ///
/// This type is created by the `channel` function and implements the `Stream` /// This type is created by the [`channel`] function and implements the
/// trait to represent received messages. /// `Stream` trait to represent received messages.
///
/// [`channel`]: fn.channel.html
pub struct Receiver<T> { pub struct Receiver<T> {
rx: PollEvented<channel::Receiver<T>>, rx: PollEvented<channel::Receiver<T>>,
} }