Expand description
A *.wat
file parser, or a parser for one parenthesized module.
This is the top-level type which you’ll frequently parse when working with
this crate. A *.wat
file is either one module
s-expression or a sequence
of s-expressions that are module fields.
Variants
Module(Module<'a>)
Component(Component<'a>)
Implementations
sourceimpl Wat<'_>
impl Wat<'_>
sourcepub fn encode(&mut self) -> Result<Vec<u8>, Error>
pub fn encode(&mut self) -> Result<Vec<u8>, Error>
Encodes this Wat
to binary form. This calls either Module::encode
or Component::encode
.
Trait Implementations
Auto Trait Implementations
impl<'a> RefUnwindSafe for Wat<'a>
impl<'a> Send for Wat<'a>
impl<'a> Sync for Wat<'a>
impl<'a> Unpin for Wat<'a>
impl<'a> UnwindSafe for Wat<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more