We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
any
1 parent f944161 commit 7c82b89Copy full SHA for 7c82b89
src/fn/closures/closure_examples/iter_any.md
@@ -13,8 +13,9 @@ pub trait Iterator {
13
// and modified, but not consumed.
14
fn any<F>(&mut self, f: F) -> bool where
15
// `FnMut` meaning any captured variable may at most be
16
- // modified, not consumed. `Self::Item` states it takes
17
- // arguments to the closure by value.
+ // modified, not consumed. `Self::Item` is the closure parameter type,
+ // which is determined by the iterator (e.g., `&T` for `.iter()`,
18
+ // `T` for `.into_iter()`).
19
F: FnMut(Self::Item) -> bool;
20
}
21
```
0 commit comments