@@ -352,7 +352,6 @@ fn for_each() {
352
352
353
353
// Iterate over amt with dirty cache
354
354
let mut x = 0 ;
355
- #[ allow( deprecated) ]
356
355
a. for_each ( |_, _: & BytesDe | {
357
356
x += 1 ;
358
357
Ok ( ( ) )
@@ -367,7 +366,6 @@ fn for_each() {
367
366
assert_eq ! ( new_amt. count( ) , indexes. len( ) as u64 ) ;
368
367
369
368
let mut x = 0 ;
370
- #[ allow( deprecated) ]
371
369
new_amt
372
370
. for_each ( |i, _: & BytesDe | {
373
371
if i != indexes[ x] {
@@ -382,7 +380,6 @@ fn for_each() {
382
380
. unwrap ( ) ;
383
381
assert_eq ! ( x, indexes. len( ) ) ;
384
382
385
- #[ allow( deprecated) ]
386
383
new_amt. for_each ( |_, _: & BytesDe | Ok ( ( ) ) ) . unwrap ( ) ;
387
384
assert_eq ! (
388
385
c. to_string( ) . as_str( ) ,
@@ -420,7 +417,6 @@ fn for_each_ranged() {
420
417
// Iterate over amt with dirty cache from different starting values
421
418
for start_val in 0 ..RANGE {
422
419
let mut retrieved_values = Vec :: new ( ) ;
423
- #[ allow( deprecated) ]
424
420
let ( count, next_key) = a
425
421
. for_each_while_ranged ( Some ( start_val) , None , |index, _: & BytesDe | {
426
422
retrieved_values. push ( index) ;
@@ -436,7 +432,6 @@ fn for_each_ranged() {
436
432
437
433
// Iterate out of bounds
438
434
for i in [ RANGE , RANGE + 1 , 2 * RANGE , 8 * RANGE ] {
439
- #[ allow( deprecated) ]
440
435
let ( count, next_key) = a
441
436
. for_each_while_ranged ( Some ( i) , None , |_, _: & BytesDe | {
442
437
panic ! ( "didn't expect to iterate" )
@@ -449,7 +444,6 @@ fn for_each_ranged() {
449
444
// Iterate over amt with dirty cache with different page sizes
450
445
for page_size in 1 ..=RANGE {
451
446
let mut retrieved_values = Vec :: new ( ) ;
452
- #[ allow( deprecated) ]
453
447
let ( count, next_key) = a
454
448
. for_each_while_ranged ( None , Some ( page_size) , |index, _: & BytesDe | {
455
449
retrieved_values. push ( index) ;
@@ -471,7 +465,6 @@ fn for_each_ranged() {
471
465
let mut retrieved_values = Vec :: new ( ) ;
472
466
let mut start_cursor = None ;
473
467
loop {
474
- #[ allow( deprecated) ]
475
468
let ( num_traversed, next_cursor) = a
476
469
. for_each_while_ranged ( start_cursor, Some ( page_size) , |idx, _val| {
477
470
retrieved_values. push ( idx) ;
@@ -497,7 +490,6 @@ fn for_each_ranged() {
497
490
let mut retrieved_values = Vec :: new ( ) ;
498
491
let mut start_cursor = None ;
499
492
loop {
500
- #[ allow( deprecated) ]
501
493
let ( num_traversed, next_cursor) = a
502
494
. for_each_ranged ( start_cursor, Some ( page_size) , |idx, _val : & BytesDe | {
503
495
retrieved_values. push ( idx) ;
@@ -523,7 +515,6 @@ fn for_each_ranged() {
523
515
524
516
// Iterate over the amt with dirty cache ignoring gaps in the address space including at the
525
517
// beginning of the amt, we should only see the values that were not deleted
526
- #[ allow( deprecated) ]
527
518
let ( num_traversed, next_cursor) = a
528
519
. for_each_while_ranged ( Some ( 0 ) , Some ( 501 ) , |i, _v| {
529
520
assert_eq ! ( ( i / 10 ) % 2 , 1 ) ; // only "odd" batches of ten 10 - 19, 30 - 39, etc. should be present
@@ -536,7 +527,6 @@ fn for_each_ranged() {
536
527
// flush the amt to the blockstore, reload and repeat the test with a clean cache
537
528
let cid = a. flush ( ) . unwrap ( ) ;
538
529
let a = Amt :: load ( & cid, & db) . unwrap ( ) ;
539
- #[ allow( deprecated) ]
540
530
let ( num_traversed, next_cursor) = a
541
531
. for_each_while_ranged ( Some ( 0 ) , Some ( 501 ) , |i, _v : & BytesDe | {
542
532
assert_eq ! ( ( i / 10 ) % 2 , 1 ) ; // only "odd" batches of ten 10 - 19, 30 - 39, etc. should be present
@@ -632,7 +622,6 @@ fn new_from_iter() {
632
622
633
623
let a: Amt < String , _ > = Amt :: load ( & k, & mem) . unwrap ( ) ;
634
624
let mut restored = Vec :: new ( ) ;
635
- #[ allow( deprecated) ]
636
625
a. for_each ( |k, v| {
637
626
restored. push ( ( k as usize , v. clone ( ) ) ) ;
638
627
Ok ( ( ) )
0 commit comments