]> git.proxmox.com Git - rustc.git/blob - src/test/ui/generator/type-mismatch-signature-deduction.stderr
New upstream version 1.48.0~beta.8+dfsg1
[rustc.git] / src / test / ui / generator / type-mismatch-signature-deduction.stderr
1 error[E0308]: mismatched types
2 --> $DIR/type-mismatch-signature-deduction.rs:13:9
3 |
4 LL | 5
5 | ^ expected enum `std::result::Result`, found integer
6 |
7 = note: expected type `std::result::Result<{integer}, _>`
8 found type `{integer}`
9
10 error[E0271]: type mismatch resolving `<[generator@$DIR/type-mismatch-signature-deduction.rs:6:5: 14:6 _] as Generator>::Return == i32`
11 --> $DIR/type-mismatch-signature-deduction.rs:5:13
12 |
13 LL | fn foo() -> impl Generator<Return = i32> {
14 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected enum `std::result::Result`, found `i32`
15 |
16 = note: expected enum `std::result::Result<{integer}, _>`
17 found type `i32`
18 = note: the return type of a function must have a statically known size
19
20 error: aborting due to 2 previous errors
21
22 Some errors have detailed explanations: E0271, E0308.
23 For more information about an error, try `rustc --explain E0271`.