Struct resast::stmt::IfStmt [−][src]
pub struct IfStmt<'a> {
pub test: Expr<'a>,
pub consequent: Box<Stmt<'a>>,
pub alternate: Option<Box<Stmt<'a>>>,
}
Expand description
An if statement
if (1 < 2) {
console.log('Always true');
} else {
console.log('Never true');
}
Fields
test: Expr<'a>
consequent: Box<Stmt<'a>>
alternate: Option<Box<Stmt<'a>>>
Trait Implementations
Auto Trait Implementations
impl<'a> RefUnwindSafe for IfStmt<'a>
impl<'a> UnwindSafe for IfStmt<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more