pub struct HeapRegion { /* private fields */ }
Expand description
A memory region to be used as heap memory
Implementations§
source§impl HeapRegion
impl HeapRegion
sourcepub unsafe fn new(
heap_bottom: *mut u8,
size: usize,
capabilities: EnumSet<MemoryCapability>,
) -> Self
pub unsafe fn new( heap_bottom: *mut u8, size: usize, capabilities: EnumSet<MemoryCapability>, ) -> Self
Create a new HeapRegion with the given capabilities
§Safety
- The supplied memory region must be available for the entire program
(
'static
). - The supplied memory region must be exclusively available to the heap only, no aliasing.
size > 0
.
Auto Trait Implementations§
impl Freeze for HeapRegion
impl RefUnwindSafe for HeapRegion
impl Send for HeapRegion
impl !Sync for HeapRegion
impl Unpin for HeapRegion
impl UnwindSafe for HeapRegion
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more