]> git.proxmox.com Git - rustc.git/blame - src/test/ui/return/return-impl-trait.stderr
Update unsuspicious file list
[rustc.git] / src / test / ui / return / return-impl-trait.stderr
CommitLineData
5099ac24
FG
1error[E0308]: mismatched types
2 --> $DIR/return-impl-trait.rs:15:5
3 |
4LL | fn bar<T: Trait + std::marker::Sync>() -> T
5 | - -
6 | | |
7 | | expected `T` because of return type
8 | this type parameter help: consider using an impl return type: `impl Trait + std::marker::Sync + Send`
9...
10LL | ()
11 | ^^ expected type parameter `T`, found `()`
12 |
13 = note: expected type parameter `T`
14 found unit type `()`
15
16error[E0308]: mismatched types
17 --> $DIR/return-impl-trait.rs:23:5
18 |
19LL | fn other_bounds<T>() -> T
20 | - -
21 | | |
22 | | expected `T` because of return type
23 | | help: consider using an impl return type: `impl Trait`
24 | this type parameter
25...
26LL | ()
27 | ^^ expected type parameter `T`, found `()`
28 |
29 = note: expected type parameter `T`
30 found unit type `()`
31
32error: aborting due to 2 previous errors
33
34For more information about this error, try `rustc --explain E0308`.