error[E0308]: mismatched types | |
--> $DIR/issue-5358-1.rs:6:9 | |
| | |
LL | match S(Either::Left(5)) { | |
| ------------------ this match expression has type `S` | |
LL | Either::Right(_) => {} | |
| ^^^^^^^^^^^^^^^^ expected struct `S`, found enum `Either` | |
| | |
= note: expected struct `S` | |
found enum `Either<_, _>` | |
error: aborting due to previous error | |
For more information about this error, try `rustc --explain E0308`. |