pub trait MemoryView<Store>: MemoryWritable<Store> + MemoryReadable<Store>where
Store: Store,{
// Required method
fn check_bounds(
&self,
store: &mut <Store as Store>::ActualStore<'_>,
offset: u32,
size: u32
) -> Result<(), MemoryAccessError>;
}
Required Methods§
sourcefn check_bounds(
&self,
store: &mut <Store as Store>::ActualStore<'_>,
offset: u32,
size: u32
) -> Result<(), MemoryAccessError>
fn check_bounds( &self, store: &mut <Store as Store>::ActualStore<'_>, offset: u32, size: u32 ) -> Result<(), MemoryAccessError>
For optimization purposes, user must check bounds first, then try read-write to memory
MemoryWritable
and MemoryReadable
functions will panic in case of out of bounds access`
Object Safety§
This trait is not object safe.