MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / source_mut

Method source_mut

crates/core/src/error/error.rs:1720–1731  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

1718 }
1719
1720 fn source_mut(&mut self) -> Option<&mut Error> {
1721 match self.unpack_mut() {
1722 OomOrDynErrorMut::DynError(e) => {
1723 // Safety: invariant of this type.
1724 let vtable = unsafe { e.as_ref().vtable };
1725 // Safety: using the vtable associated with this pointer's
1726 // concrete type and the pointer is valid.
1727 unsafe { (vtable.source_mut)(e.raw_copy()) }
1728 }
1729 OomOrDynErrorMut::Oom(_) => None,
1730 }
1731 }
1732
1733 fn is<E>(&self) -> bool
1734 where

Callers 2

error_ext_chain_mutMethod · 0.80
error_ext_zipMethod · 0.80

Calls 3

unpack_mutMethod · 0.80
raw_copyMethod · 0.80
as_refMethod · 0.45

Tested by

no test coverage detected