From 71dfb94beaeac107d7cd359985f9bd66fd223e1b Mon Sep 17 00:00:00 2001 From: Aurojit Panda Date: Mon, 21 Jan 2019 12:45:09 -0800 Subject: [PATCH] fixup! Fix allocator --- framework/src/allocators/cache_aligned.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/src/allocators/cache_aligned.rs b/framework/src/allocators/cache_aligned.rs index a2b8e1f710..66c4de38cc 100644 --- a/framework/src/allocators/cache_aligned.rs +++ b/framework/src/allocators/cache_aligned.rs @@ -1,4 +1,4 @@ -use std::alloc::{self, Alloc, Global, Layout, Opaque}; +use std::alloc::{self, Alloc, Global, Layout}; use std::fmt; use std::mem::size_of; use std::ops::{Deref, DerefMut}; @@ -18,7 +18,7 @@ impl Drop for CacheAligned { fn drop(&mut self) { unsafe { alloc::Global.dealloc( - NonNull::::new_unchecked(self.ptr.as_ptr() as *mut Opaque), + NonNull::::new_unchecked(self.ptr.as_ptr() as *mut u8), Layout::from_size_align(size_of::(), CACHE_LINE_SIZE).unwrap(), ); }