pub struct WasmFunction {
pub name: String,
pub param_types: Vec<WasmValueType>,
pub return_types: Vec<WasmValueType>,
pub bytecode: Vec<u8>,
pub local_types: Vec<WasmValueType>,
}Expand description
A WASM function with metadata and executable bytecode.
bytecode = [local_decl_count : LEB128] (count LEB128 + type byte)* expression_opcodes
An empty bytecode is treated as an empty function that returns with no values.
Fields§
§name: String§param_types: Vec<WasmValueType>§return_types: Vec<WasmValueType>§bytecode: Vec<u8>§local_types: Vec<WasmValueType>Trait Implementations§
Source§impl Clone for WasmFunction
impl Clone for WasmFunction
Source§fn clone(&self) -> WasmFunction
fn clone(&self) -> WasmFunction
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WasmFunction
impl RefUnwindSafe for WasmFunction
impl Send for WasmFunction
impl Sync for WasmFunction
impl Unpin for WasmFunction
impl UnsafeUnpin for WasmFunction
impl UnwindSafe for WasmFunction
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