pub struct LocalInit {
pub eq_token: Eq,
pub expr: Box<Expr>,
pub diverge: Option<(Else, Box<Expr>)>,
}
Expand description
The expression assigned in a local let
binding, including optional
diverging else
block.
LocalInit
represents = s.parse()?
in let x: u64 = s.parse()?
and
= r else { return }
in let Ok(x) = r else { return }
.
Fields§
§eq_token: Eq
§expr: Box<Expr>
§diverge: Option<(Else, Box<Expr>)>
Trait Implementations§
source§impl PartialEq for LocalInit
impl PartialEq for LocalInit
impl Eq for LocalInit
Auto Trait Implementations§
impl RefUnwindSafe for LocalInit
impl !Send for LocalInit
impl !Sync for LocalInit
impl Unpin for LocalInit
impl UnwindSafe for LocalInit
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