Rollup merge of #91859 - xkr47:patch-2, r=yaahc
Iterator::cycle() — document empty iterator special case
This commit is contained in:
commit
d6c802ee7a
1 changed files with 2 additions and 1 deletions
|
@ -3028,7 +3028,8 @@ pub trait Iterator {
|
||||||
///
|
///
|
||||||
/// Instead of stopping at [`None`], the iterator will instead start again,
|
/// Instead of stopping at [`None`], the iterator will instead start again,
|
||||||
/// from the beginning. After iterating again, it will start at the
|
/// from the beginning. After iterating again, it will start at the
|
||||||
/// beginning again. And again. And again. Forever.
|
/// beginning again. And again. And again. Forever. Note that in case the
|
||||||
|
/// original iterator is empty, the resulting iterator will also be empty.
|
||||||
///
|
///
|
||||||
/// # Examples
|
/// # Examples
|
||||||
///
|
///
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue