@@ -474,15 +474,15 @@ impl<'a, K, V, Type> NodeRef<marker::Mut<'a>, K, V, Type> {
474474 ///
475475 /// # Safety
476476 /// The node has more than `idx` initialized elements.
477- pub unsafe fn key_mut_at ( & mut self , idx : usize ) -> & mut K {
477+ unsafe fn key_mut_at ( & mut self , idx : usize ) -> & mut K {
478478 unsafe { self . reborrow_mut ( ) . into_key_mut_at ( idx) }
479479 }
480480
481481 /// Borrows a mutable reference to one of the values stored in the node.
482482 ///
483483 /// # Safety
484484 /// The node has more than `idx` initialized elements.
485- pub unsafe fn val_mut_at ( & mut self , idx : usize ) -> & mut V {
485+ unsafe fn val_mut_at ( & mut self , idx : usize ) -> & mut V {
486486 unsafe { self . reborrow_mut ( ) . into_val_mut_at ( idx) }
487487 }
488488
@@ -645,7 +645,7 @@ impl<'a, K: 'a, V: 'a> NodeRef<marker::Mut<'a>, K, V, marker::Internal> {
645645
646646 /// Adds a key/value pair, and an edge to go to the left of that pair,
647647 /// to the beginning of the node.
648- pub fn push_front ( & mut self , key : K , val : V , edge : Root < K , V > ) {
648+ fn push_front ( & mut self , key : K , val : V , edge : Root < K , V > ) {
649649 assert ! ( edge. height == self . height - 1 ) ;
650650 assert ! ( self . len( ) < CAPACITY ) ;
651651
@@ -1001,18 +1001,18 @@ impl<'a, K: 'a, V: 'a> Handle<NodeRef<marker::Mut<'a>, K, V, marker::Internal>,
10011001 let ( middle_kv_idx, insertion) = splitpoint ( self . idx ) ;
10021002 let middle = unsafe { Handle :: new_kv ( self . node , middle_kv_idx) } ;
10031003 let ( mut left, k, v, mut right) = middle. split ( ) ;
1004- match insertion {
1004+ let mut insertion_edge = match insertion {
10051005 InsertionPlace :: Left ( insert_idx) => unsafe {
1006- Handle :: new_edge ( left. reborrow_mut ( ) , insert_idx) . insert_fit ( key , val , edge ) ;
1006+ Handle :: new_edge ( left. reborrow_mut ( ) , insert_idx)
10071007 } ,
10081008 InsertionPlace :: Right ( insert_idx) => unsafe {
10091009 Handle :: new_edge (
10101010 right. node_as_mut ( ) . cast_unchecked :: < marker:: Internal > ( ) ,
10111011 insert_idx,
10121012 )
1013- . insert_fit ( key, val, edge) ;
10141013 } ,
1015- }
1014+ } ;
1015+ insertion_edge. insert_fit ( key, val, edge) ;
10161016 InsertResult :: Split ( SplitResult { left : left. forget_type ( ) , k, v, right } )
10171017 }
10181018 }
0 commit comments