Skip to content

Commit 2fcef68

Browse files
committed
fix clippy::while_let_on_iterator in tests
1 parent a3b9e42 commit 2fcef68

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/quick.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ quickcheck! {
721721

722722
assert_eq!(expected_first, curr_perm);
723723

724-
while let Some(next_perm) = perms.next() {
724+
for next_perm in perms {
725725
assert!(
726726
next_perm > curr_perm,
727727
"next perm isn't greater-than current; next_perm={:?} curr_perm={:?} n={}",
@@ -1602,7 +1602,7 @@ quickcheck! {
16021602

16031603
fn is_fused<I: Iterator>(mut it: I) -> bool
16041604
{
1605-
while let Some(_) = it.next() {}
1605+
for _ in it.by_ref() {}
16061606
for _ in 0..10{
16071607
if it.next().is_some(){
16081608
return false;

0 commit comments

Comments
 (0)