pub trait VectorRefIntoWasmAbi:
WasmDescribe
+ Sized
+ VectorRefIntoWasmAbiSealed {
// Required method
fn slice_into_abi(slice: &[Self]) -> WasmSlice;
}Expand description
How a borrowed &[Self] crosses to JS.
A sequence crosses as a WasmSlice of len cells. In place, the cell is
the element itself, which is its JS encoding (numbers, and JS handles as
table indices), so the slice is borrowed (WasmSlice::borrow). Encoded,
the cell is the element’s scalar ABI, in a fresh buffer that JS decodes
with the element’s own glue and frees (WasmSlice::encode). The CLI
tells them apart by the element’s descriptor alone: numbers and JS handles
are in place, and anything else is encoded. Encoded elements are declared
once, with __wbindgen_encoded_sequence!.
Required Methods§
fn slice_into_abi(slice: &[Self]) -> WasmSlice
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".