about summary refs log tree commit diff
path: root/tests/source/pattern.rs
blob: 4192d5210851d047132d449b54b564be5aac6505 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
fn main() {
    let z = match x {
        "pat1" => 1,
        ( ref  x, ref  mut  y /*comment*/) => 2,
    };

    if let <  T as  Trait   > :: CONST = ident {
        do_smth();
    }

    let Some ( ref   xyz  /*   comment!   */) = opt;

    if let  None  =   opt2 { panic!("oh noes"); }
}