From bc150cd0b56cf6dcb7c4feab64e83b9938faa186 Mon Sep 17 00:00:00 2001 From: Pen Tree Date: Thu, 21 Nov 2019 04:24:17 +0800 Subject: [PATCH] Fix doc links (#1799) Link fix only. After this fix, `cargo doc --package` succeeds. --- tokio/src/fs/mod.rs | 2 +- tokio/src/fs/read_dir.rs | 2 +- tokio/src/lib.rs | 4 ++-- tokio/src/net/tcp/listener.rs | 2 +- tokio/src/net/tcp/mod.rs | 2 +- tokio/src/net/tcp/stream.rs | 2 +- tokio/src/net/udp/socket.rs | 2 +- tokio/src/net/unix/datagram.rs | 2 +- tokio/src/net/unix/listener.rs | 2 +- tokio/src/net/unix/stream.rs | 2 +- tokio/src/process/mod.rs | 2 +- tokio/src/runtime/mod.rs | 2 +- tokio/src/time/interval.rs | 2 +- 13 files changed, 14 insertions(+), 14 deletions(-) diff --git a/tokio/src/fs/mod.rs b/tokio/src/fs/mod.rs index 937242803..c9e4e637e 100644 --- a/tokio/src/fs/mod.rs +++ b/tokio/src/fs/mod.rs @@ -6,7 +6,7 @@ //! //! Tasks run by *worker* threads should not block, as this could delay //! servicing reactor events. Portable filesystem operations are blocking, -//! however. This module offers adapters which use a [`blocking`] annotation +//! however. This module offers adapters which use a `blocking` annotation //! to inform the runtime that a blocking operation is required. When //! necessary, this allows the runtime to convert the current thread from a //! *worker* to a *backup* thread, where blocking is acceptable. diff --git a/tokio/src/fs/read_dir.rs b/tokio/src/fs/read_dir.rs index 219c7b354..d252eabb9 100644 --- a/tokio/src/fs/read_dir.rs +++ b/tokio/src/fs/read_dir.rs @@ -36,7 +36,7 @@ pub async fn read_dir(path: impl AsRef) -> io::Result { /// /// [`read_dir`]: read_dir /// [`DirEntry`]: DirEntry -/// [`Stream`]: Stream +/// [`Stream`]: futures_core::Stream /// [`Err`]: std::result::Result::Err #[derive(Debug)] #[must_use = "streams do nothing unless polled"] diff --git a/tokio/src/lib.rs b/tokio/src/lib.rs index d1c4397ca..aa08aeeb3 100644 --- a/tokio/src/lib.rs +++ b/tokio/src/lib.rs @@ -22,11 +22,11 @@ //! IOCP, etc...). //! * Asynchronous [TCP and UDP][net] sockets. //! * Asynchronous [filesystem][fs] operations. -//! * [Timer][timer] API for scheduling work in the future. +//! * [Timer][time] API for scheduling work in the future. //! //! Guide level documentation is found on the [website]. //! -//! [driver]: tokio::net::driver +//! [driver]: driver/index.html //! [website]: https://tokio.rs/docs/ //! //! # Examples diff --git a/tokio/src/net/tcp/listener.rs b/tokio/src/net/tcp/listener.rs index 33316bad0..5db5ee805 100644 --- a/tokio/src/net/tcp/listener.rs +++ b/tokio/src/net/tcp/listener.rs @@ -304,7 +304,7 @@ impl TryFrom for mio::net::TcpListener { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: TcpListener) -> Result { value.io.into_inner() } diff --git a/tokio/src/net/tcp/mod.rs b/tokio/src/net/tcp/mod.rs index 9ad88424b..929a1e008 100644 --- a/tokio/src/net/tcp/mod.rs +++ b/tokio/src/net/tcp/mod.rs @@ -7,7 +7,7 @@ //! [`connect`] method, which returns a future which returns a `TcpStream`. //! //! To listen on an address [`TcpListener`] can be used. `TcpListener`'s -//! [`incoming`][incoming_method] method can be used to accept new connections. +//! [`incoming`][TcpListener::incoming] method can be used to accept new connections. //! It return the [`Incoming`] struct, which implements a stream which returns //! `TcpStream`s. //! diff --git a/tokio/src/net/tcp/stream.rs b/tokio/src/net/tcp/stream.rs index f1905d879..b73114b42 100644 --- a/tokio/src/net/tcp/stream.rs +++ b/tokio/src/net/tcp/stream.rs @@ -720,7 +720,7 @@ impl TryFrom for mio::net::TcpStream { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: TcpStream) -> Result { value.io.into_inner() } diff --git a/tokio/src/net/udp/socket.rs b/tokio/src/net/udp/socket.rs index 41768f1f1..30cc104e3 100644 --- a/tokio/src/net/udp/socket.rs +++ b/tokio/src/net/udp/socket.rs @@ -367,7 +367,7 @@ impl TryFrom for mio::net::UdpSocket { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: UdpSocket) -> Result { value.io.into_inner() } diff --git a/tokio/src/net/unix/datagram.rs b/tokio/src/net/unix/datagram.rs index a26480cb1..eb8bfe4cb 100644 --- a/tokio/src/net/unix/datagram.rs +++ b/tokio/src/net/unix/datagram.rs @@ -201,7 +201,7 @@ impl TryFrom for mio_uds::UnixDatagram { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: UnixDatagram) -> Result { value.io.into_inner() } diff --git a/tokio/src/net/unix/listener.rs b/tokio/src/net/unix/listener.rs index c7c853350..7791b05f9 100644 --- a/tokio/src/net/unix/listener.rs +++ b/tokio/src/net/unix/listener.rs @@ -102,7 +102,7 @@ impl TryFrom for mio_uds::UnixListener { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: UnixListener) -> Result { value.io.into_inner() } diff --git a/tokio/src/net/unix/stream.rs b/tokio/src/net/unix/stream.rs index 83d3c8d60..7a2269947 100644 --- a/tokio/src/net/unix/stream.rs +++ b/tokio/src/net/unix/stream.rs @@ -118,7 +118,7 @@ impl TryFrom for mio_uds::UnixStream { /// See [`PollEvented::into_inner`] for more details about /// resource deregistration that happens during the call. /// - /// [`PollEvented::into_inner`]: crate::util::PollEvented::into_inner + /// [`PollEvented::into_inner`]: crate::io::PollEvented::into_inner fn try_from(value: UnixStream) -> Result { value.io.into_inner() } diff --git a/tokio/src/process/mod.rs b/tokio/src/process/mod.rs index ee43a9fb0..63d6f19eb 100644 --- a/tokio/src/process/mod.rs +++ b/tokio/src/process/mod.rs @@ -101,7 +101,7 @@ //! While similar to the standard library, this crate's `Child` type differs //! importantly in the behavior of `drop`. In the standard library, a child //! process will continue running after the instance of [`std::process::Child`] -//! is dropped. In this crate, however, because [`tokio::process::Child`] is a +//! is dropped. In this crate, however, because [`tokio::process::Child`][Child] is a //! future of the child's `ExitStatus`, a child process is terminated if //! `tokio::process::Child` is dropped. The behavior of the standard library can //! be regained with the [`Child::forget`](crate::process::Child::forget) method. diff --git a/tokio/src/runtime/mod.rs b/tokio/src/runtime/mod.rs index a022f955f..81f282555 100644 --- a/tokio/src/runtime/mod.rs +++ b/tokio/src/runtime/mod.rs @@ -119,7 +119,7 @@ //! } //! ``` //! -//! [driver]: tokio::net::driver +//! [driver]: crate::io::driver //! [executor]: https://tokio.rs/docs/internals/runtime-model/#executors //! [`Runtime`]: struct.Runtime.html //! [`Reactor`]: ../reactor/struct.Reactor.html diff --git a/tokio/src/time/interval.rs b/tokio/src/time/interval.rs index f9fa1127b..70daf47da 100644 --- a/tokio/src/time/interval.rs +++ b/tokio/src/time/interval.rs @@ -75,7 +75,7 @@ pub fn interval_at(start: Instant, period: Duration) -> Interval { } } -/// Stream returned by [`instant`](instant) and [`instant_at`](instant_at). +/// Stream returned by [`interval`](interval) and [`interval_at`](interval_at). #[derive(Debug)] pub struct Interval { /// Future that completes the next time the `Interval` yields a value.