pub enum Initializer {
Integer {
span: Span,
value: i64,
},
UnsignedInteger {
span: Span,
value: u64,
},
Float {
span: Span,
value: f64,
},
Symbol {
span: Span,
name: String,
},
Cast {
span: Span,
ty: InitializerCastType,
expr: Box<Initializer>,
},
Generic {
span: Span,
expr: Box<Initializer>,
},
Masked {
span: Span,
mask: u64,
value: Box<Initializer>,
},
List {
span: Span,
values: Vec<Initializer>,
},
Unary {
span: Span,
op: InitializerUnaryOp,
expr: Box<Initializer>,
},
Binary {
span: Span,
op: InitializerBinaryOp,
left: Box<Initializer>,
right: Box<Initializer>,
},
Conditional {
span: Span,
condition: Box<Initializer>,
then_expr: Box<Initializer>,
else_expr: Box<Initializer>,
},
}Variants§
Integer
UnsignedInteger
Float
Symbol
Cast
Generic
Masked
List
Unary
Binary
Conditional
Trait Implementations§
Source§impl Clone for Initializer
impl Clone for Initializer
Source§fn clone(&self) -> Initializer
fn clone(&self) -> Initializer
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 Initializer
impl Debug for Initializer
Source§impl PartialEq for Initializer
impl PartialEq for Initializer
Source§fn eq(&self, other: &Initializer) -> bool
fn eq(&self, other: &Initializer) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for Initializer
Auto Trait Implementations§
impl Freeze for Initializer
impl RefUnwindSafe for Initializer
impl Send for Initializer
impl Sync for Initializer
impl Unpin for Initializer
impl UnsafeUnpin for Initializer
impl UnwindSafe for Initializer
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