1 // Copyright 2012 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
11 #![allow(non_shorthand_field_patterns)]
13 #![allow(unused_variables)]
14 // pretty-expanded FIXME #23616
16 #![feature(slice_patterns)]
18 struct Foo(isize, isize, isize, isize);
19 struct Bar{a: isize, b: isize, c: isize, d: isize}
22 let Foo(..) = Foo(5, 5, 5, 5);
23 let Foo(..) = Foo(5, 5, 5, 5);
24 let Bar{..} = Bar{a: 5, b: 5, c: 5, d: 5};
25 let (..) = (5, 5, 5, 5);
26 let Foo(a, b, ..) = Foo(5, 5, 5, 5);
27 let Foo(.., d) = Foo(5, 5, 5, 5);
28 let (a, b, ..) = (5, 5, 5, 5);
29 let (.., c, d) = (5, 5, 5, 5);
30 let Bar{b: b, ..} = Bar{a: 5, b: 5, c: 5, d: 5};