pub struct Table { /* private fields */ }Expand description
A table is a vector of opaque values of a particular reference type. The ๐๐๐ size in the limits of the table type specifies the initial size of that table, while its ๐๐บ๐, if present, restricts the size to which it can grow later. Tables can be initialized through element segments. Tables are referenced through table indices, starting with the smallest index not referencing a table import. Most constructs implicitly reference table index 0.
See https://webassembly.github.io/spec/core/syntax/modules.html#tables
ยงExamples
use wasm_ast::{Table, TableType, Limit, ReferenceType};
let limit = Limit::bounded(1, 2);
let kind = TableType::new( ReferenceType::Function,limit);
let table = Table::new(kind);
assert_eq!(table, kind.into());
assert_eq!(table.kind(), &kind);Implementationsยง
Trait Implementationsยง
impl Copy for Table
impl Eq for Table
impl StructuralPartialEq for Table
Auto Trait Implementationsยง
impl Freeze for Table
impl RefUnwindSafe for Table
impl Send for Table
impl Sync for Table
impl Unpin for Table
impl UnwindSafe for Table
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