about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDenis Vasilik <contact@denisvasilik.com>2020-09-02 18:32:46 +0200
committerDenis Vasilik <contact@denisvasilik.com>2020-09-02 18:32:46 +0200
commit7cf0fe1d02dceafa8e7f9a9276e501c8889262af (patch)
tree2f0853a229895d07ce3b15e31c9d0a48bfeb3d91
parent07cd4c8778a219f681f78dfb3c8ee123f630b06d (diff)
downloadrust-7cf0fe1d02dceafa8e7f9a9276e501c8889262af.tar.gz
rust-7cf0fe1d02dceafa8e7f9a9276e501c8889262af.zip
Apply suggestions from review
-rw-r--r--library/core/src/iter/traits/iterator.rs12
1 files changed, 9 insertions, 3 deletions
diff --git a/library/core/src/iter/traits/iterator.rs b/library/core/src/iter/traits/iterator.rs
index d26db581b58..12fa213740c 100644
--- a/library/core/src/iter/traits/iterator.rs
+++ b/library/core/src/iter/traits/iterator.rs
@@ -22,8 +22,8 @@ fn _assert_is_object_safe(_: &dyn Iterator<Item = ()>) {}
 /// generally, please see the [module-level documentation]. In particular, you
 /// may want to know how to [implement `Iterator`][impl].
 ///
-/// [module-level documentation]: crate::iter
-/// [impl]: crate::iter#implementing-iterator
+/// [module-level documentation]: self
+/// [impl]: self#implementing-iterator
 #[stable(feature = "rust1", since = "1.0.0")]
 #[rustc_on_unimplemented(
     on(
@@ -107,6 +107,8 @@ pub trait Iterator {
     /// again may or may not eventually start returning [`Some(Item)`] again at some
     /// point.
     ///
+    /// [`Some(Item)`]: Some
+    ///
     /// # Examples
     ///
     /// Basic usage:
@@ -447,7 +449,6 @@ pub trait Iterator {
     /// }
     /// ```
     ///
-    /// [`once`]: crate::iter::once
     /// [`OsStr`]: ../../std/ffi/struct.OsStr.html
     #[inline]
     #[stable(feature = "rust1", since = "1.0.0")]
@@ -2157,6 +2158,8 @@ pub trait Iterator {
     /// argument is a double reference. You can see this effect in the
     /// examples below, with `&&x`.
     ///
+    /// [`Some(element)`]: Some
+    ///
     /// # Examples
     ///
     /// Basic usage:
@@ -2301,6 +2304,7 @@ pub trait Iterator {
     /// This function might panic if the iterator has more than `usize::MAX`
     /// non-matching elements.
     ///
+    /// [`Some(index)`]: Some
     /// [`usize::MAX`]: crate::usize::MAX
     ///
     /// # Examples
@@ -2362,6 +2366,8 @@ pub trait Iterator {
     /// `rposition()` is short-circuiting; in other words, it will stop
     /// processing as soon as it finds a `true`.
     ///
+    /// [`Some(index)`]: Some
+    ///
     /// # Examples
     ///
     /// Basic usage: