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.
impl FusedIterator for Permutations
1 parent 06721b8 commit 4f049caCopy full SHA for 4f049ca
src/permutations.rs
@@ -1,6 +1,7 @@
1
use alloc::vec::Vec;
2
use std::fmt;
3
use std::iter::once;
4
+use std::iter::FusedIterator;
5
6
use super::lazy_buffer::LazyBuffer;
7
use crate::size_hint::{self, SizeHint};
@@ -131,6 +132,13 @@ where
131
132
}
133
134
135
+impl<I> FusedIterator for Permutations<I>
136
+where
137
+ I: Iterator,
138
+ I::Item: Clone,
139
+{
140
+}
141
+
142
fn advance(indices: &mut [usize], cycles: &mut [usize]) -> bool {
143
let n = indices.len();
144
let k = cycles.len();
0 commit comments