pub struct Heap { /* private fields */ }Expand description
A finite heap: a partial map from addresses to values.
Implementations§
Source§impl Heap
impl Heap
Sourcepub fn read(&self, addr: u64) -> Option<u64>
pub fn read(&self, addr: u64) -> Option<u64>
Read a value from the heap. Returns None if unallocated.
Sourcepub fn is_disjoint(&self, other: &Self) -> bool
pub fn is_disjoint(&self, other: &Self) -> bool
Check whether two heaps are disjoint (non-overlapping domains).
Sourcepub fn disjoint_union(&self, other: &Self) -> Self
pub fn disjoint_union(&self, other: &Self) -> Self
Form the disjoint union of two heaps (panics if they overlap).
Trait Implementations§
impl Eq for Heap
impl StructuralPartialEq for Heap
Auto Trait Implementations§
impl Freeze for Heap
impl RefUnwindSafe for Heap
impl Send for Heap
impl Sync for Heap
impl Unpin for Heap
impl UnsafeUnpin for Heap
impl UnwindSafe for Heap
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