Struct syn::Arm
[−]
[src]
pub struct Arm { pub attrs: Vec<Attribute>, pub pats: Vec<Pat>, pub guard: Option<Box<Expr>>, pub body: Box<Expr>, }
An arm of a 'match'.
E.g. 0...10 => { println!("match!") }
as in
ⓘThis example is not tested
match n { 0...10 => { println!("match!") }, // .. }
Fields
attrs: Vec<Attribute>
pats: Vec<Pat>
guard: Option<Box<Expr>>
body: Box<Expr>
Trait Implementations
impl ToTokens for Arm
[src]
impl Debug for Arm
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Clone for Arm
[src]
fn clone(&self) -> Arm
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Eq for Arm
[src]
impl PartialEq for Arm
[src]
fn eq(&self, __arg_0: &Arm) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Arm) -> bool
[src]
This method tests for !=
.