Struct wasm_encoder::FunctionSection [−][src]
pub struct FunctionSection { /* fields omitted */ }
Expand description
An encoder for the function section.
Example
use wasm_encoder::{Module, FunctionSection, ValType}; let mut functions = FunctionSection::new(); let type_index = 0; functions.function(type_index); let mut module = Module::new(); module.section(&functions); // Note: this will generate an invalid module because we didn't generate a // code section containing the function body. See the documentation for // `CodeSection` for details. let wasm_bytes = module.finish();
Implementations
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for FunctionSection
impl Send for FunctionSection
impl Sync for FunctionSection
impl Unpin for FunctionSection
impl UnwindSafe for FunctionSection
Blanket Implementations
Mutably borrows from an owned value. Read more