avoid MaybeUninit::get_mut where it is not needed

This commit is contained in:
Ralf Jung 2018-12-02 12:34:39 +01:00
parent f4f8b211a8
commit ebe69c06b3
1 changed files with 2 additions and 2 deletions

View File

@ -602,7 +602,7 @@ impl<'a, K: 'a, V: 'a, Type> NodeRef<marker::Mut<'a>, K, V, Type> {
} else {
unsafe {
slice::from_raw_parts_mut(
self.as_leaf_mut().keys.get_mut() as *mut [K] as *mut K,
self.as_leaf_mut().keys.as_mut_ptr() as *mut K,
self.len()
)
}
@ -613,7 +613,7 @@ impl<'a, K: 'a, V: 'a, Type> NodeRef<marker::Mut<'a>, K, V, Type> {
debug_assert!(!self.is_shared_root());
unsafe {
slice::from_raw_parts_mut(
self.as_leaf_mut().vals.get_mut() as *mut [V] as *mut V,
self.as_leaf_mut().vals.as_mut_ptr() as *mut V,
self.len()
)
}