pub struct Let {
pub ident: Token,
pub initializer: Box<Expr>,
pub type_annotation: Option<TypeAnnotation>,
}Expand description
Represents a variable declaration (let statement) in the AST.
A let statement declares a new variable with an optional type annotation and initializer.
Fields§
§ident: TokenThe token representing the identifier (variable name).
initializer: Box<Expr>The expression used to initialize the variable.
type_annotation: Option<TypeAnnotation>An optional type annotation specifying the type of the variable.
Trait Implementations§
impl StructuralPartialEq for Let
Auto Trait Implementations§
impl Freeze for Let
impl RefUnwindSafe for Let
impl Send for Let
impl Sync for Let
impl Unpin for Let
impl UnwindSafe for Let
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