@@ -809,7 +809,7 @@ impl<K, V, S, A: Allocator> HashMap<K, V, S, A> {
809809 #[ cfg( test) ]
810810 #[ cfg_attr( feature = "inline-more" , inline) ]
811811 fn raw_capacity ( & self ) -> usize {
812- self . table . buckets ( )
812+ self . table . num_buckets ( )
813813 }
814814
815815 /// Returns the number of elements in the map.
@@ -6565,10 +6565,10 @@ mod test_map {
65656565 Ok ( map) => map,
65666566 Err ( msg) => return msg,
65676567 } ;
6568- if map. table . buckets ( ) != scope_map. table . buckets ( ) {
6568+ if map. table . num_buckets ( ) != scope_map. table . num_buckets ( ) {
65696569 return format ! (
6570- "map.table.buckets () != scope_map.table.buckets (),\n left: `{}`,\n right: `{}`" ,
6571- map. table. buckets ( ) , scope_map. table. buckets ( )
6570+ "map.table.num_buckets () != scope_map.table.num_buckets (),\n left: `{}`,\n right: `{}`" ,
6571+ map. table. num_buckets ( ) , scope_map. table. num_buckets ( )
65726572 ) ;
65736573 }
65746574 map. clone_from ( & scope_map) ;
@@ -6590,7 +6590,7 @@ mod test_map {
65906590 assert_eq ! ( unsafe { map. table. iter( ) . count( ) } , 0 ) ;
65916591 assert_eq ! ( unsafe { map. table. iter( ) . iter. count( ) } , 0 ) ;
65926592
6593- for idx in 0 ..map. table . buckets ( ) {
6593+ for idx in 0 ..map. table . num_buckets ( ) {
65946594 let idx = idx as u64 ;
65956595 assert ! (
65966596 map. table. find( idx, |( k, _) | * k == idx) . is_none( ) ,
@@ -6633,10 +6633,10 @@ mod test_map {
66336633 Ok ( map) => map,
66346634 Err ( msg) => return msg,
66356635 } ;
6636- if map. table . buckets ( ) == scope_map. table . buckets ( ) {
6636+ if map. table . num_buckets ( ) == scope_map. table . num_buckets ( ) {
66376637 return format ! (
6638- "map.table.buckets () == scope_map.table.buckets (): `{}`" ,
6639- map. table. buckets ( )
6638+ "map.table.num_buckets () == scope_map.table.num_buckets (): `{}`" ,
6639+ map. table. num_buckets ( )
66406640 ) ;
66416641 }
66426642 map. clone_from ( & scope_map) ;
@@ -6658,7 +6658,7 @@ mod test_map {
66586658 assert_eq ! ( unsafe { map. table. iter( ) . count( ) } , 0 ) ;
66596659 assert_eq ! ( unsafe { map. table. iter( ) . iter. count( ) } , 0 ) ;
66606660
6661- for idx in 0 ..map. table . buckets ( ) {
6661+ for idx in 0 ..map. table . num_buckets ( ) {
66626662 let idx = idx as u64 ;
66636663 assert ! (
66646664 map. table. find( idx, |( k, _) | * k == idx) . is_none( ) ,
0 commit comments