pub enum ExprKind {
Constant,
Variable,
Function {
arity: usize,
},
Array,
Attribute,
LogicalOp,
Conditional,
}Expand description
Classifies the kind of expression node in the AST.
This enum is used to categorize expression nodes at a higher level than the specific AST node variants, making it easier to determine the general type of an expression without matching on all variants.
Variants§
Constant
A constant numerical value.
Variable
A variable reference.
Function
A function call with a specific arity (number of arguments).
Array
An array element access.
Attribute
An object attribute access.
LogicalOp
A logical operation (AND/OR).
Conditional
A conditional (ternary) operation.
Trait Implementations§
impl Copy for ExprKind
impl Eq for ExprKind
impl StructuralPartialEq for ExprKind
Auto Trait Implementations§
impl Freeze for ExprKind
impl RefUnwindSafe for ExprKind
impl Send for ExprKind
impl Sync for ExprKind
impl Unpin for ExprKind
impl UnwindSafe for ExprKind
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)