Struct wasm_encoder::component::AdapterFunctionSection [−][src]
pub struct AdapterFunctionSection { /* fields omitted */ }
Expand description
An encoder for the component adapter function section.
Example
use wasm_encoder::component::{Component, AdapterFunctionSection, CanonicalOption};
// This assumes there is an adapter function type with
// index 0 and a target function with index 0.
let mut adapters = AdapterFunctionSection::new();
adapters.adapter(0, &[CanonicalOption::UTF8], 0);
let mut component = Component::new();
component.section(&adapters);
let bytes = component.finish();
Implementations
Trait Implementations
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for AdapterFunctionSection
impl Send for AdapterFunctionSection
impl Sync for AdapterFunctionSection
impl Unpin for AdapterFunctionSection
impl UnwindSafe for AdapterFunctionSection
Blanket Implementations
Mutably borrows from an owned value. Read more