Struct parity_wasm::elements::NameSection
source · [−]pub struct NameSection { /* private fields */ }
Expand description
Debug name information.
Implementations
sourceimpl 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).
sourceimpl NameSection
impl NameSection
Trait Implementations
sourceimpl Clone for NameSection
impl Clone for NameSection
sourcefn clone(&self) -> NameSection
fn clone(&self) -> NameSection
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for NameSection
impl Debug for NameSection
sourceimpl PartialEq<NameSection> for NameSection
impl PartialEq<NameSection> for NameSection
sourcefn 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 ==
. Read more
sourcefn ne(&self, other: &NameSection) -> bool
fn ne(&self, other: &NameSection) -> bool
This method tests for !=
.
sourceimpl 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
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more