pub trait RefIntoWasmAbi: Sealed {
type Abi: WasmAbi;
// Required methods
fn describe_ref();
fn ref_into_abi(&self) -> Self::Abi;
}Expand description
A type whose shared references can cross the Wasm ABI, i.e.
for<'a> &'a Self: IntoWasmAbi.
Rust does not imply a trait’s where clauses on Self the way it implies
supertraits, so an alias trait for that higher-ranked bound would not let
generic code use &T: IntoWasmAbi. This trait carries the conversion
itself instead, and experimental_generic_mono imports marshal a &T
argument through it, so T: RefIntoWasmAbi is the bound they declare. It
is sealed, holding exactly where the higher-ranked bound does.
§⚠️ Unstable
This is part of the internal convert module, no
stability guarantees are provided. Use at your own risk. See its
documentation for more details.
Required Associated Types§
Required Methods§
Sourcefn describe_ref()
fn describe_ref()
Describe &Self.
Sourcefn ref_into_abi(&self) -> Self::Abi
fn ref_into_abi(&self) -> Self::Abi
Convert &self into Self::Abi.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".