]>
Commit | Line | Data |
---|---|---|
1b1a35ee | 1 | error[E0277]: the trait bound `Foo: Qux` is not satisfied in `impl Future` |
ba9703b0 | 2 | --> $DIR/issue-64130-3-other.rs:24:5 |
60c5eb7d | 3 | | |
dfeec247 | 4 | LL | async fn bar() { |
1b1a35ee | 5 | | - within this `impl Future` |
60c5eb7d XL |
6 | ... |
7 | LL | is_qux(bar()); | |
1b1a35ee | 8 | | ^^^^^^ within `impl Future`, the trait `Qux` is not implemented for `Foo` |
60c5eb7d | 9 | | |
60c5eb7d | 10 | note: future does not implement `Qux` as this value is used across an await |
ba9703b0 | 11 | --> $DIR/issue-64130-3-other.rs:18:5 |
60c5eb7d XL |
12 | | |
13 | LL | let x = Foo; | |
ba9703b0 | 14 | | - has type `Foo` which does not implement `Qux` |
60c5eb7d XL |
15 | LL | baz().await; |
16 | | ^^^^^^^^^^^ await occurs here, with `x` maybe used later | |
17 | LL | } | |
18 | | - `x` is later dropped here | |
94222f64 XL |
19 | note: required by a bound in `is_qux` |
20 | --> $DIR/issue-64130-3-other.rs:14:14 | |
21 | | | |
22 | LL | fn is_qux<T: Qux>(t: T) { } | |
23 | | ^^^ required by this bound in `is_qux` | |
60c5eb7d XL |
24 | |
25 | error: aborting due to previous error | |
26 | ||
27 | For more information about this error, try `rustc --explain E0277`. |