]> git.proxmox.com Git - rustc.git/blame - tests/ui/issues/issue-5358-1.stderr
New upstream version 1.76.0+dfsg1
[rustc.git] / tests / ui / issues / issue-5358-1.stderr
CommitLineData
8faf50e0 1error[E0308]: mismatched types
0731742a 2 --> $DIR/issue-5358-1.rs:6:9
8faf50e0 3 |
0731742a 4LL | match S(Either::Left(5)) {
dfeec247 5 | ------------------ this expression has type `S`
8faf50e0 6LL | Either::Right(_) => {}
9ffffee4 7 | ^^^^^^^^^^^^^^^^ expected `S`, found `Either<_, _>`
8faf50e0 8 |
60c5eb7d
XL
9 = note: expected struct `S`
10 found enum `Either<_, _>`
5e7ed085
FG
11help: try wrapping the pattern in `S`
12 |
13LL | S(Either::Right(_)) => {}
14 | ++ +
3c0e092e
XL
15help: you might have meant to use field `0` whose type is `Either<usize, usize>`
16 |
17LL | match S(Either::Left(5)).0 {
18 | ~~~~~~~~~~~~~~~~~~~~
8faf50e0 19
4b012472 20error: aborting due to 1 previous error
8faf50e0
XL
21
22For more information about this error, try `rustc --explain E0308`.