about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSteve Klabnik <steve@steveklabnik.com>2015-11-05 12:43:02 +0100
committerSteve Klabnik <steve@steveklabnik.com>2015-11-05 12:43:02 +0100
commit444e8d6d01afcf6c8d0a3cca79aa53cf27713ba6 (patch)
treefd02ae20b94c66557cd6d4a83b1de967331da8cd
parent268e360f39532c702b4cdc28d313c52454010d79 (diff)
parentb0ca03923359afc8df92a802b7cc1476a72fb2d0 (diff)
downloadrust-444e8d6d01afcf6c8d0a3cca79aa53cf27713ba6.tar.gz
rust-444e8d6d01afcf6c8d0a3cca79aa53cf27713ba6.zip
Rollup merge of #29539 - shepmaster:empty-iterator-docs, r=Gankro
-rw-r--r--src/libcore/iter.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/libcore/iter.rs b/src/libcore/iter.rs
index f1199919fcb..9b260b57099 100644
--- a/src/libcore/iter.rs
+++ b/src/libcore/iter.rs
@@ -1565,6 +1565,8 @@ pub trait Iterator {
     /// as soon as it finds a `false`, given that no matter what else happens,
     /// the result will also be `false`.
     ///
+    /// An empty iterator returns `true`.
+    ///
     /// # Examples
     ///
     /// Basic usage:
@@ -1613,6 +1615,8 @@ pub trait Iterator {
     /// as soon as it finds a `true`, given that no matter what else happens,
     /// the result will also be `true`.
     ///
+    /// An empty iterator returns `false`.
+    ///
     /// # Examples
     ///
     /// Basic usage:
@@ -2071,6 +2075,8 @@ pub trait Iterator {
     ///
     /// Takes each element, adds them together, and returns the result.
     ///
+    /// An empty iterator returns the zero value of the type.
+    ///
     /// # Examples
     ///
     /// Basic usage:
@@ -2094,6 +2100,8 @@ pub trait Iterator {
 
     /// Iterates over the entire iterator, multiplying all the elements
     ///
+    /// An empty iterator returns the one value of the type.
+    ///
     /// # Examples
     ///
     /// ```