Skip to content

Commit a11cfa2

Browse files
committed
Reduce hard-coded documentation link usage
1 parent 93172f2 commit a11cfa2

4 files changed

Lines changed: 9 additions & 9 deletions

File tree

library/core/src/io/cursor.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use crate::io::{self, ErrorKind, IoSlice, SeekFrom, Write};
2222
/// [bytes]: crate::slice "slice"
2323
/// [`File`]: ../../std/fs/struct.File.html
2424
/// [`Read`]: ../../std/io/trait.Read.html
25-
/// [`Write`]: ../../std/io/trait.Write.html
25+
/// [`Write`]: crate::io::Write
2626
/// [`Seek`]: ../../std/io/trait.Seek.html
2727
/// [Vec]: ../../alloc/vec/struct.Vec.html
2828
///

library/core/src/io/error.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ pub type Result<T> = result::Result<T, Error>;
7171
/// [`ErrorKind`].
7272
///
7373
/// [Read]: ../../std/io/trait.Read.html
74-
/// [Write]: ../../std/io/trait.Write.html
75-
/// [Seek]: ../../std/io/trait.Seek.html
74+
/// [Write]: crate::io::Write
75+
/// [Seek]: crate::io::Seek
7676
#[stable(feature = "rust1", since = "1.0.0")]
7777
#[rustc_has_incoherent_inherent_impls]
7878
pub struct Error {
@@ -841,7 +841,7 @@ pub enum ErrorKind {
841841
/// particular number of bytes but only a smaller number of bytes could be
842842
/// written.
843843
///
844-
/// [write]: ../../std/io/trait.Write.html#tymethod.write
844+
/// [write]: crate::io::Write::write
845845
/// [`Ok(0)`]: Ok
846846
#[stable(feature = "rust1", since = "1.0.0")]
847847
WriteZero,

library/core/src/io/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ pub use self::{
5656
///
5757
/// [file]: ../../std/fs/struct.File.html
5858
/// [arc]: ../../alloc/sync/struct.Arc.html
59-
/// [`Write`]: ../../std/io/trait.Write.html
60-
/// [`Seek`]: ../../std/io/trait.Seek.html
59+
/// [`Write`]: crate::io::Write
60+
/// [`Seek`]: crate::io::Seek
6161
#[doc(hidden)]
6262
#[unstable(feature = "core_io_internals", reason = "exposed only for libstd", issue = "none")]
6363
pub trait IoHandle {}

library/core/src/io/util.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use crate::{cmp, fmt};
44
/// `Empty` ignores any data written via [`Write`], and will always be empty
55
/// (returning zero bytes) when read via [`Read`].
66
///
7-
/// [`Write`]: ../../std/io/trait.Write.html
7+
/// [`Write`]: crate::io::Write
88
/// [`Read`]: ../../std/io/trait.Read.html
99
///
1010
/// This struct is generally created by calling [`empty()`]. Please
@@ -129,7 +129,7 @@ impl Seek for Empty {
129129
/// [`Ok(buf.len())`]: Ok
130130
/// [`Ok(0)`]: Ok
131131
///
132-
/// [`write`]: ../../std/io/trait.Write.html#tymethod.write
132+
/// [`write`]: crate::io::Write::write
133133
/// [`read`]: ../../std/io/trait.Read.html#tymethod.read
134134
///
135135
/// # Examples
@@ -303,7 +303,7 @@ impl Write for &Sink {
303303
/// All calls to [`write`] on the returned instance will return [`Ok(buf.len())`]
304304
/// and the contents of the buffer will not be inspected.
305305
///
306-
/// [`write`]: ../../std/io/trait.Write.html#tymethod.write
306+
/// [`write`]: crate::io::Write::write
307307
/// [`Ok(buf.len())`]: Ok
308308
///
309309
/// # Examples

0 commit comments

Comments
 (0)