Skip to content

Commit f82f3be

Browse files
committed
Auto merge of rust-lang#73819 - euclio:rustdoc-summaries, r=jyn514,GuillaumeGomez
rustdoc: do not use plain summary for trait impls Fixes rust-lang#38386. Fixes rust-lang#48332. Fixes rust-lang#49430. Fixes rust-lang#62741. Fixes rust-lang#73474. Unfortunately this is not quite ready to go because the newly-working links trigger a bunch of linkcheck failures. The failures are tough to fix because the links are resolved relative to the implementor, which could be anywhere in the module hierarchy. (In the current docs, these links end up rendering as uninterpreted markdown syntax, so I don't think these failures are any worse than the status quo. It might be acceptable to just add them to the linkchecker whitelist.) Ideally this could be fixed with intra-doc links ~~but it isn't working for me: I am currently investigating if it's possible to solve it this way.~~ Opened rust-lang#73829. EDIT: This is now ready!
2 parents 803274f + b2c6f85 commit f82f3be

File tree

5 files changed

+10
-12
lines changed

5 files changed

+10
-12
lines changed

core/src/fmt/mod.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,8 +168,6 @@ pub trait Write {
168168
/// This method should generally not be invoked manually, but rather through
169169
/// the [`write!`] macro itself.
170170
///
171-
/// [`write!`]: ../../std/macro.write.html
172-
///
173171
/// # Examples
174172
///
175173
/// ```

core/src/iter/traits/double_ended.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ pub trait DoubleEndedIterator: Iterator {
148148
/// This is the reverse version of [`try_fold()`]: it takes elements
149149
/// starting from the back of the iterator.
150150
///
151-
/// [`try_fold()`]: trait.Iterator.html#method.try_fold
151+
/// [`try_fold()`]: Iterator::try_fold
152152
///
153153
/// # Examples
154154
///
@@ -213,7 +213,7 @@ pub trait DoubleEndedIterator: Iterator {
213213
/// Folding is useful whenever you have a collection of something, and want
214214
/// to produce a single value from it.
215215
///
216-
/// [`fold()`]: trait.Iterator.html#method.fold
216+
/// [`fold()`]: Iterator::fold
217217
///
218218
/// # Examples
219219
///

core/src/slice/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3319,7 +3319,7 @@ pub unsafe trait SliceIndex<T: ?Sized>: private_slice_index::Sealed {
33193319
/// Calling this method with an out-of-bounds index or a dangling `slice` pointer
33203320
/// is *[undefined behavior]* even if the resulting reference is not used.
33213321
///
3322-
/// [undefined behavior]: ../../reference/behavior-considered-undefined.html
3322+
/// [undefined behavior]: https://doc.rust-lang.org/reference/behavior-considered-undefined.html
33233323
#[unstable(feature = "slice_index_methods", issue = "none")]
33243324
unsafe fn get_unchecked(self, slice: *const T) -> *const Self::Output;
33253325

@@ -3328,7 +3328,7 @@ pub unsafe trait SliceIndex<T: ?Sized>: private_slice_index::Sealed {
33283328
/// Calling this method with an out-of-bounds index or a dangling `slice` pointer
33293329
/// is *[undefined behavior]* even if the resulting reference is not used.
33303330
///
3331-
/// [undefined behavior]: ../../reference/behavior-considered-undefined.html
3331+
/// [undefined behavior]: https://doc.rust-lang.org/reference/behavior-considered-undefined.html
33323332
#[unstable(feature = "slice_index_methods", issue = "none")]
33333333
unsafe fn get_unchecked_mut(self, slice: *mut T) -> *mut Self::Output;
33343334

std/src/os/linux/fs.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ pub trait MetadataExt {
196196
fn st_atime(&self) -> i64;
197197
/// Returns the last access time of the file, in nanoseconds since [`st_atime`].
198198
///
199-
/// [`st_atime`]: #tymethod.st_atime
199+
/// [`st_atime`]: Self::st_atime
200200
///
201201
/// # Examples
202202
///
@@ -232,7 +232,7 @@ pub trait MetadataExt {
232232
fn st_mtime(&self) -> i64;
233233
/// Returns the last modification time of the file, in nanoseconds since [`st_mtime`].
234234
///
235-
/// [`st_mtime`]: #tymethod.st_mtime
235+
/// [`st_mtime`]: Self::st_mtime
236236
///
237237
/// # Examples
238238
///
@@ -268,7 +268,7 @@ pub trait MetadataExt {
268268
fn st_ctime(&self) -> i64;
269269
/// Returns the last status change time of the file, in nanoseconds since [`st_ctime`].
270270
///
271-
/// [`st_ctime`]: #tymethod.st_ctime
271+
/// [`st_ctime`]: Self::st_ctime
272272
///
273273
/// # Examples
274274
///

std/src/os/redox/fs.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ pub trait MetadataExt {
200200
fn st_atime(&self) -> i64;
201201
/// Returns the last access time of the file, in nanoseconds since [`st_atime`].
202202
///
203-
/// [`st_atime`]: #tymethod.st_atime
203+
/// [`st_atime`]: Self::st_atime
204204
///
205205
/// # Examples
206206
///
@@ -236,7 +236,7 @@ pub trait MetadataExt {
236236
fn st_mtime(&self) -> i64;
237237
/// Returns the last modification time of the file, in nanoseconds since [`st_mtime`].
238238
///
239-
/// [`st_mtime`]: #tymethod.st_mtime
239+
/// [`st_mtime`]: Self::st_mtime
240240
///
241241
/// # Examples
242242
///
@@ -272,7 +272,7 @@ pub trait MetadataExt {
272272
fn st_ctime(&self) -> i64;
273273
/// Returns the last status change time of the file, in nanoseconds since [`st_ctime`].
274274
///
275-
/// [`st_ctime`]: #tymethod.st_ctime
275+
/// [`st_ctime`]: Self::st_ctime
276276
///
277277
/// # Examples
278278
///

0 commit comments

Comments
 (0)