init
This commit is contained in:
10
src/alloc/mod.rs
Normal file
10
src/alloc/mod.rs
Normal file
@@ -0,0 +1,10 @@
|
||||
use core::alloc::{GlobalAlloc, Layout};
|
||||
use core::ptr::null_mut;
|
||||
|
||||
pub struct Allocator;
|
||||
unsafe impl GlobalAlloc for Allocator {
|
||||
unsafe fn alloc(&self, _layout: Layout) -> *mut u8 {
|
||||
return null_mut();
|
||||
}
|
||||
unsafe fn dealloc(&self, _ptr: *mut u8, _layout: Layout) {}
|
||||
}
|
Reference in New Issue
Block a user