pub struct SwitchStmt {
pub leading_comments: Vec<Comment>,
pub switch_span: Span,
pub paren_span: (Span, Span),
pub selector: Expr,
pub brace_span: (Span, Span),
pub cases: Vec<SwitchCaseGroup>,
}Expand description
A switch statement.
Fields§
§leading_comments: Vec<Comment>§switch_span: Span§paren_span: (Span, Span)§selector: Expr§brace_span: (Span, Span)§cases: Vec<SwitchCaseGroup>Implementations§
Trait Implementations§
Source§impl Clone for SwitchStmt
impl Clone for SwitchStmt
Source§fn clone(&self) -> SwitchStmt
fn clone(&self) -> SwitchStmt
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SwitchStmt
impl Debug for SwitchStmt
impl Eq for SwitchStmt
Source§impl Hash for SwitchStmt
impl Hash for SwitchStmt
Source§impl PartialEq for SwitchStmt
impl PartialEq for SwitchStmt
Source§fn eq(&self, other: &SwitchStmt) -> bool
fn eq(&self, other: &SwitchStmt) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for SwitchStmt
Auto Trait Implementations§
impl Freeze for SwitchStmt
impl RefUnwindSafe for SwitchStmt
impl Send for SwitchStmt
impl Sync for SwitchStmt
impl Unpin for SwitchStmt
impl UnsafeUnpin for SwitchStmt
impl UnwindSafe for SwitchStmt
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