fn main() {
let p = Point { x: 0, y: 0 };
let Point { .., y } = p; //~ ERROR expected `}`, found `,`
- //~| ERROR pattern does not mention field `x`
- //~| ERROR pattern does not mention field `y`
+ //~| ERROR pattern does not mention fields `x`, `y`
}
LL | let Point { .., y } = p; //~ ERROR expected `}`, found `,`
| ^ `..` must be in the last position, and cannot have a trailing comma
-error[E0027]: pattern does not mention field `x`
+error[E0027]: pattern does not mention fields `x`, `y`
--> $DIR/issue-49257.rs:20:9
|
LL | let Point { .., y } = p; //~ ERROR expected `}`, found `,`
- | ^^^^^^^^^^^^^^^ missing field `x`
+ | ^^^^^^^^^^^^^^^ missing fields `x`, `y`
-error[E0027]: pattern does not mention field `y`
- --> $DIR/issue-49257.rs:20:9
- |
-LL | let Point { .., y } = p; //~ ERROR expected `}`, found `,`
- | ^^^^^^^^^^^^^^^ missing field `y`
-
-error: aborting due to 3 previous errors
+error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0027`.