summaryrefslogtreecommitdiffstats
path: root/tokio/src/io
diff options
context:
space:
mode:
authorAlice Ryhl <alice@ryhl.io>2020-07-24 21:56:38 +0200
committerGitHub <noreply@github.com>2020-07-24 12:56:38 -0700
commit4fca1974e9d9f95fab7d723619294cb4b2dcebbb (patch)
treeb44bd16a594adff645d8342656c3cdfcff0c54f3 /tokio/src/io
parent08872c55d161cac08f4feb3e141883a47ab766cf (diff)
net: ensure that unix sockets have both split and into_split (#2687)
The documentation build failed with errors such as error: `[read]` public documentation for `take` links to a private item --> tokio/src/io/util/async_read_ext.rs:1078:9 | 1078 | / /// Creates an adaptor which reads at most `limit` bytes from it. 1079 | | /// 1080 | | /// This function returns a new instance of `AsyncRead` which will read 1081 | | /// at most `limit` bytes, after which it will always return EOF ... | 1103 | | /// } 1104 | | /// ``` | |_______________^ | note: the lint level is defined here --> tokio/src/lib.rs:13:9 | 13 | #![deny(intra_doc_link_resolution_failure)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: the link appears in this line: bytes read and future calls to [`read()`][read] may succeed.
Diffstat (limited to 'tokio/src/io')
-rw-r--r--tokio/src/io/util/async_read_ext.rs10
-rw-r--r--tokio/src/io/util/async_write_ext.rs2
2 files changed, 9 insertions, 3 deletions
diff --git a/tokio/src/io/util/async_read_ext.rs b/tokio/src/io/util/async_read_ext.rs
index e848a5d2..1ed7e6cf 100644
--- a/tokio/src/io/util/async_read_ext.rs
+++ b/tokio/src/io/util/async_read_ext.rs
@@ -986,10 +986,12 @@ cfg_io_util! {
///
/// All bytes read from this source will be appended to the specified
/// buffer `buf`. This function will continuously call [`read()`] to
- /// append more data to `buf` until [`read()`][read] returns `Ok(0)`.
+ /// append more data to `buf` until [`read()`] returns `Ok(0)`.
///
/// If successful, the total number of bytes read is returned.
///
+ /// [`read()`]: fn@crate::io::AsyncReadExt::read
+ ///
/// # Errors
///
/// If a read error is encountered then the `read_to_end` operation
@@ -1018,7 +1020,7 @@ cfg_io_util! {
/// (See also the [`tokio::fs::read`] convenience function for reading from a
/// file.)
///
- /// [`tokio::fs::read`]: crate::fs::read::read
+ /// [`tokio::fs::read`]: fn@crate::fs::read
fn read_to_end<'a>(&'a mut self, buf: &'a mut Vec<u8>) -> ReadToEnd<'a, Self>
where
Self: Unpin,
@@ -1078,7 +1080,9 @@ cfg_io_util! {
/// This function returns a new instance of `AsyncRead` which will read
/// at most `limit` bytes, after which it will always return EOF
/// (`Ok(0)`). Any read errors will not count towards the number of
- /// bytes read and future calls to [`read()`][read] may succeed.
+ /// bytes read and future calls to [`read()`] may succeed.
+ ///
+ /// [`read()`]: fn@crate::io::AsyncReadExt::read
///
/// # Examples
///
diff --git a/tokio/src/io/util/async_write_ext.rs b/tokio/src/io/util/async_write_ext.rs
index fa410974..321301e2 100644
--- a/tokio/src/io/util/async_write_ext.rs
+++ b/tokio/src/io/util/async_write_ext.rs
@@ -976,6 +976,8 @@ cfg_io_util! {
/// no longer attempt to write to the stream. For example, the
/// `TcpStream` implementation will issue a `shutdown(Write)` sys call.
///
+ /// [`flush`]: fn@crate::io::AsyncWriteExt::flush
+ ///
/// # Examples
///
/// ```no_run