2019-01-20 13:26:46 -06:00
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-57741.rs:20:9
|
|
|
|
|
|
|
|
|
LL | let y = match x {
|
|
|
|
| -
|
|
|
|
| |
|
2020-09-02 02:40:56 -05:00
|
|
|
| this expression has type `Box<T>`
|
2019-01-20 13:26:46 -06:00
|
|
|
| help: consider dereferencing the boxed value: `*x`
|
|
|
|
LL | T::A(a) | T::B(a) => a,
|
2020-09-02 02:40:56 -05:00
|
|
|
| ^^^^^^^ expected struct `Box`, found enum `T`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
2020-09-02 02:40:56 -05:00
|
|
|
= note: expected struct `Box<T>`
|
2019-11-13 16:16:56 -06:00
|
|
|
found enum `T`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-57741.rs:20:19
|
|
|
|
|
|
|
|
|
LL | let y = match x {
|
|
|
|
| -
|
|
|
|
| |
|
2020-09-02 02:40:56 -05:00
|
|
|
| this expression has type `Box<T>`
|
2019-01-20 13:26:46 -06:00
|
|
|
| help: consider dereferencing the boxed value: `*x`
|
|
|
|
LL | T::A(a) | T::B(a) => a,
|
2020-09-02 02:40:56 -05:00
|
|
|
| ^^^^^^^ expected struct `Box`, found enum `T`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
2020-09-02 02:40:56 -05:00
|
|
|
= note: expected struct `Box<T>`
|
2019-11-13 16:16:56 -06:00
|
|
|
found enum `T`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-57741.rs:27:9
|
|
|
|
|
|
|
|
|
LL | let y = match x {
|
|
|
|
| -
|
|
|
|
| |
|
2020-09-02 02:40:56 -05:00
|
|
|
| this expression has type `Box<S>`
|
2019-01-20 13:26:46 -06:00
|
|
|
| help: consider dereferencing the boxed value: `*x`
|
|
|
|
LL | S::A { a } | S::B { b: a } => a,
|
2020-09-02 02:40:56 -05:00
|
|
|
| ^^^^^^^^^^ expected struct `Box`, found enum `S`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
2020-09-02 02:40:56 -05:00
|
|
|
= note: expected struct `Box<S>`
|
2019-11-13 16:16:56 -06:00
|
|
|
found enum `S`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-57741.rs:27:22
|
|
|
|
|
|
|
|
|
LL | let y = match x {
|
|
|
|
| -
|
|
|
|
| |
|
2020-09-02 02:40:56 -05:00
|
|
|
| this expression has type `Box<S>`
|
2019-01-20 13:26:46 -06:00
|
|
|
| help: consider dereferencing the boxed value: `*x`
|
|
|
|
LL | S::A { a } | S::B { b: a } => a,
|
2020-09-02 02:40:56 -05:00
|
|
|
| ^^^^^^^^^^^^^ expected struct `Box`, found enum `S`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
2020-09-02 02:40:56 -05:00
|
|
|
= note: expected struct `Box<S>`
|
2019-11-13 16:16:56 -06:00
|
|
|
found enum `S`
|
2019-01-20 13:26:46 -06:00
|
|
|
|
|
|
|
error: aborting due to 4 previous errors
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0308`.
|