Struct solang_parser::pt::EnumDefinition
source · pub struct EnumDefinition {
pub loc: Loc,
pub name: Option<Identifier>,
pub values: Vec<Option<Identifier>>,
}
Expand description
An enum definition.
enum <name> { <values>,* }
Fields§
§loc: Loc
The code location.
name: Option<Identifier>
The identifier.
This field is None
only if an error occurred during parsing.
values: Vec<Option<Identifier>>
The list of values.
This field contains None
only if an error occurred during parsing.
Trait Implementations§
source§impl Clone for EnumDefinition
impl Clone for EnumDefinition
source§fn clone(&self) -> EnumDefinition
fn clone(&self) -> EnumDefinition
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 CodeLocation for EnumDefinition
impl CodeLocation for EnumDefinition
source§impl Debug for EnumDefinition
impl Debug for EnumDefinition
source§impl Display for EnumDefinition
impl Display for EnumDefinition
source§impl PartialEq for EnumDefinition
impl PartialEq for EnumDefinition
source§fn eq(&self, other: &EnumDefinition) -> bool
fn eq(&self, other: &EnumDefinition) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for EnumDefinition
impl StructuralEq for EnumDefinition
impl StructuralPartialEq for EnumDefinition
Auto Trait Implementations§
impl RefUnwindSafe for EnumDefinition
impl Send for EnumDefinition
impl Sync for EnumDefinition
impl Unpin for EnumDefinition
impl UnwindSafe for EnumDefinition
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