Struct wiggle::wasmtime::WasmtimeGuestMemory
source · pub struct WasmtimeGuestMemory<'a> { /* private fields */ }
Expand description
Lightweight wasmtime::Memory
wrapper so we can implement the
wiggle::GuestMemory
trait on it.
Implementations§
Trait Implementations§
source§impl GuestMemory for WasmtimeGuestMemory<'_>
impl GuestMemory for WasmtimeGuestMemory<'_>
source§fn base(&self) -> &[UnsafeCell<u8>]
fn base(&self) -> &[UnsafeCell<u8>]
Returns the base allocation of this guest memory, located in host
memory. Read more
Acquires a shared borrow on a region of memory. Read more
source§fn mut_borrow(&self, r: Region) -> Result<BorrowHandle, GuestError>
fn mut_borrow(&self, r: Region) -> Result<BorrowHandle, GuestError>
Acquires a mutable borrow on a region of memory. Read more
Undoes a borrow by
shared_borrow
.source§fn mut_unborrow(&self, h: BorrowHandle)
fn mut_unborrow(&self, h: BorrowHandle)
Undoes a borrow by
mut_borrow
.Check if the underlying memory is shared across multiple threads; e.g.,
with a WebAssembly shared memory.
impl Send for WasmtimeGuestMemory<'_>
impl Sync for WasmtimeGuestMemory<'_>
Auto Trait Implementations§
impl<'a> !Freeze for WasmtimeGuestMemory<'a>
impl<'a> !RefUnwindSafe for WasmtimeGuestMemory<'a>
impl<'a> Unpin for WasmtimeGuestMemory<'a>
impl<'a> !UnwindSafe for WasmtimeGuestMemory<'a>
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