Skip to content

Commit 4da9f10

Browse files
authored
Document optimizations enabled by FusedIterator
When reading this I wondered what “some significant optimizations” referred to. As far as I can tell, the specialization of `.fuse()` is the only case where `FusedIterator` has any impact at all. Is this accurate @Stebalien?
1 parent 0195812 commit 4da9f10

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/libcore/iter/traits.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -960,7 +960,7 @@ impl<T, U, E> Product<Result<U, E>> for Result<T, E>
960960
///
961961
/// Calling next on a fused iterator that has returned `None` once is guaranteed
962962
/// to return [`None`] again. This trait should be implemented by all iterators
963-
/// that behave this way because it allows for some significant optimizations.
963+
/// that behave this way because it allows optimizing [`Iterator::fuse`].
964964
///
965965
/// Note: In general, you should not use `FusedIterator` in generic bounds if
966966
/// you need a fused iterator. Instead, you should just call [`Iterator::fuse`]

0 commit comments

Comments
 (0)