pub struct IfData {
pub condition: Expr,
pub then_branch: Box<Stmt>,
pub else_branch: Option<Box<Stmt>>,
}Expand description
Represents an if statement’s data in the language.
Fields§
§condition: ExprThe condition to check.
then_branch: Box<Stmt>The statement to execute if the condition is true.
else_branch: Option<Box<Stmt>>The statement to execute if the condition is false (optional).
Trait Implementations§
impl StructuralPartialEq for IfData
Auto Trait Implementations§
impl Freeze for IfData
impl RefUnwindSafe for IfData
impl Send for IfData
impl Sync for IfData
impl Unpin for IfData
impl UnwindSafe for IfData
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