about summary refs log tree commit diff
diff options
context:
space:
mode:
authorArtur Kovacs <kovacs.artur.barnabas@gmail.com>2019-11-04 22:11:52 +0100
committerArtur Kovacs <kovacs.artur.barnabas@gmail.com>2019-11-04 22:11:52 +0100
commit23be25c82f517cb9ee5c4df57378e024d3c5b3eb (patch)
treeb44bc14a4ef86afa9f8cd15fa2a96278cde92da9
parent6ce3e1df478cf4f865f4aa5d7a55bae2d87e5871 (diff)
downloadrust-23be25c82f517cb9ee5c4df57378e024d3c5b3eb.tar.gz
rust-23be25c82f517cb9ee5c4df57378e024d3c5b3eb.zip
Improve wording in the documentation of `Iterator::count()`.
-rw-r--r--src/libcore/iter/traits/iterator.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libcore/iter/traits/iterator.rs b/src/libcore/iter/traits/iterator.rs
index e9bbe330208..b7a35568e3f 100644
--- a/src/libcore/iter/traits/iterator.rs
+++ b/src/libcore/iter/traits/iterator.rs
@@ -201,13 +201,13 @@ pub trait Iterator {
 
     /// Consumes the iterator, counting the number of iterations and returning it.
     ///
-    /// This method will evaluate the iterator until its [`next`] returns
-    /// [`None`]. Once [`None`] is encountered, `count()` returns one less than the
-    /// number of times it called [`next`]. Note that [`next`] has to be called at
-    /// least once even if the iterator does not have any elements.
+    /// This method will call [`next`] repeatedly until [`None`] is encountered,
+    /// returning the number of times it saw [`Some`]. Note that [`next`] has to be
+    /// called at least once even if the iterator does not have any elements.
     ///
     /// [`next`]: #tymethod.next
     /// [`None`]: ../../std/option/enum.Option.html#variant.None
+    /// [`Some`]: ../../std/option/enum.Option.html#variant.Some
     ///
     /// # Overflow Behavior
     ///