]> git.lizzy.rs Git - rust.git/blob - tests/ui/match/issue-12552.stderr
Rollup merge of #106470 - ehuss:tidy-no-wasm, r=Mark-Simulacrum
[rust.git] / tests / ui / match / issue-12552.stderr
1 error[E0308]: mismatched types
2   --> $DIR/issue-12552.rs:6:5
3    |
4 LL |   match t {
5    |         - this expression has type `Result<_, {integer}>`
6 LL |     Some(k) => match k {
7    |     ^^^^^^^ expected enum `Result`, found enum `Option`
8    |
9    = note: expected enum `Result<_, {integer}>`
10               found enum `Option<_>`
11 help: try wrapping the pattern in `Ok`
12    |
13 LL |     Ok(Some(k)) => match k {
14    |     +++       +
15
16 error[E0308]: mismatched types
17   --> $DIR/issue-12552.rs:9:5
18    |
19 LL |   match t {
20    |         - this expression has type `Result<_, {integer}>`
21 ...
22 LL |     None => ()
23    |     ^^^^ expected enum `Result`, found enum `Option`
24    |
25    = note: expected enum `Result<_, {integer}>`
26               found enum `Option<_>`
27 help: try wrapping the pattern in `Ok`
28    |
29 LL |     Ok(None) => ()
30    |     +++    +
31
32 error: aborting due to 2 previous errors
33
34 For more information about this error, try `rustc --explain E0308`.