about summary refs log tree commit diff
path: root/src/liballoc/tests
diff options
context:
space:
mode:
Diffstat (limited to 'src/liballoc/tests')
-rw-r--r--src/liballoc/tests/heap.rs7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/liballoc/tests/heap.rs b/src/liballoc/tests/heap.rs
index 4b0d7bc1f44..709e8c148d5 100644
--- a/src/liballoc/tests/heap.rs
+++ b/src/liballoc/tests/heap.rs
@@ -1,4 +1,4 @@
-use std::alloc::{AllocInit, AllocRef, Global, Layout, MemoryBlock, System};
+use std::alloc::{AllocInit, AllocRef, Global, Layout, System};
 
 /// Issue #45955 and #62251.
 #[test]
@@ -39,10 +39,7 @@ fn check_overalign_requests<T: AllocRef>(mut allocator: T) {
 
                 // Clean up
                 for &ptr in &pointers {
-                    allocator.dealloc(MemoryBlock::new(
-                        ptr,
-                        Layout::from_size_align(size, align).unwrap(),
-                    ))
+                    allocator.dealloc(ptr, Layout::from_size_align(size, align).unwrap())
                 }
             }
         }