Struct parity_wasm::elements::NameSection
source · pub struct NameSection { /* private fields */ }
Expand description
Debug name information.
Implementations§
source§impl NameSection
impl NameSection
sourcepub fn new(
module: Option<ModuleNameSubsection>,
functions: Option<FunctionNameSubsection>,
locals: Option<LocalNameSubsection>
) -> Self
pub fn new( module: Option<ModuleNameSubsection>, functions: Option<FunctionNameSubsection>, locals: Option<LocalNameSubsection> ) -> Self
Creates a new name section.
sourcepub fn module(&self) -> Option<&ModuleNameSubsection>
pub fn module(&self) -> Option<&ModuleNameSubsection>
Module name subsection of this section.
sourcepub fn module_mut(&mut self) -> &mut Option<ModuleNameSubsection>
pub fn module_mut(&mut self) -> &mut Option<ModuleNameSubsection>
Module name subsection of this section (mutable).
sourcepub fn functions(&self) -> Option<&FunctionNameSubsection>
pub fn functions(&self) -> Option<&FunctionNameSubsection>
Functions name subsection of this section.
sourcepub fn functions_mut(&mut self) -> &mut Option<FunctionNameSubsection>
pub fn functions_mut(&mut self) -> &mut Option<FunctionNameSubsection>
Functions name subsection of this section (mutable).
sourcepub fn locals(&self) -> Option<&LocalNameSubsection>
pub fn locals(&self) -> Option<&LocalNameSubsection>
Local name subsection of this section.
sourcepub fn locals_mut(&mut self) -> &mut Option<LocalNameSubsection>
pub fn locals_mut(&mut self) -> &mut Option<LocalNameSubsection>
Local name subsection of this section (mutable).
source§impl NameSection
impl NameSection
Trait Implementations§
source§impl Clone for NameSection
impl Clone for NameSection
source§fn clone(&self) -> NameSection
fn clone(&self) -> NameSection
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for NameSection
impl Debug for NameSection
source§impl PartialEq<NameSection> for NameSection
impl PartialEq<NameSection> for NameSection
source§fn eq(&self, other: &NameSection) -> bool
fn eq(&self, other: &NameSection) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for NameSection
impl Serialize for NameSection
impl StructuralPartialEq for NameSection
Auto Trait Implementations§
impl RefUnwindSafe for NameSection
impl Send for NameSection
impl Sync for NameSection
impl Unpin for NameSection
impl UnwindSafe for NameSection
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