File tree Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -450,7 +450,13 @@ quickcheck! {
450
450
}
451
451
assert_eq!( answer, actual) ;
452
452
453
- assert_eq!( answer. into_iter( ) . last( ) , a. multi_cartesian_product( ) . last( ) ) ;
453
+ assert_eq!(
454
+ {
455
+ #[ allow( clippy:: double_ended_iterator_last) ]
456
+ answer. into_iter( ) . last( )
457
+ } ,
458
+ a. multi_cartesian_product( ) . last( )
459
+ ) ;
454
460
}
455
461
456
462
fn correct_empty_multi_product( ) -> ( ) {
Original file line number Diff line number Diff line change @@ -503,7 +503,10 @@ quickcheck! {
503
503
}
504
504
505
505
check_results_specialized!( it, |i| i. count( ) ) ;
506
- check_results_specialized!( it, |i| i. last( ) ) ;
506
+ check_results_specialized!( it, |i| {
507
+ #[ allow( clippy:: double_ended_iterator_last) ]
508
+ i. last( )
509
+ } ) ;
507
510
check_results_specialized!( it, |i| i. collect:: <Vec <_>>( ) ) ;
508
511
check_results_specialized!( it, |i| i. rev( ) . collect:: <Vec <_>>( ) ) ;
509
512
check_results_specialized!( it, |i| {
Original file line number Diff line number Diff line change @@ -281,6 +281,7 @@ fn count_clones() {
281
281
let f = Foo { n : Cell :: new ( 0 ) } ;
282
282
let it = it:: repeat_n ( f, n) ;
283
283
// drain it
284
+ #[ allow( clippy:: double_ended_iterator_last) ]
284
285
let last = it. last ( ) ;
285
286
if n == 0 {
286
287
assert_eq ! ( last, None ) ;
You can’t perform that action at this time.
0 commit comments