fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #66089 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4560ea788cb

1.39.0
944 B33 linesraw
1error[E0642]: patterns aren't allowed in methods without bodies
2  --> $DIR/E0642.rs:5:12
3   |
4LL |     fn foo((x, y): (i32, i32));
5   |            ^^^^^^
6help: give this argument a name or use an underscore to ignore it
7   |
8LL |     fn foo(_: (i32, i32));
9   |            ^
10
11error[E0642]: patterns aren't allowed in methods without bodies
12  --> $DIR/E0642.rs:7:12
13   |
14LL |     fn bar((x, y): (i32, i32)) {}
15   |            ^^^^^^
16help: give this argument a name or use an underscore to ignore it
17   |
18LL |     fn bar(_: (i32, i32)) {}
19   |            ^
20
21error[E0642]: patterns aren't allowed in methods without bodies
22  --> $DIR/E0642.rs:9:15
23   |
24LL |     fn method(S { .. }: S) {}
25   |               ^^^^^^^^
26help: give this argument a name or use an underscore to ignore it
27   |
28LL |     fn method(_: S) {}
29   |               ^
30
31error: aborting due to 3 previous errors
32
33For more information about this error, try `rustc --explain E0642`.