]> git.lizzy.rs Git - rust.git/blob - src/test/ui/async-await/issue-64130-3-other.stderr
Merge commit 'd3a2366ee877075c59b38bd8ced55f224fc7ef51' into sync_cg_clif-2022-07-26
[rust.git] / src / test / ui / async-await / issue-64130-3-other.stderr
1 error[E0277]: the trait bound `Foo: Qux` is not satisfied in `impl Future<Output = ()>`
2   --> $DIR/issue-64130-3-other.rs:24:12
3    |
4 LL | async fn bar() {
5    |                - within this `impl Future<Output = ()>`
6 ...
7 LL |     is_qux(bar());
8    |            ^^^^^ within `impl Future<Output = ()>`, the trait `Qux` is not implemented for `Foo`
9    |
10 note: future does not implement `Qux` as this value is used across an await
11   --> $DIR/issue-64130-3-other.rs:18:10
12    |
13 LL |     let x = Foo;
14    |         - has type `Foo` which does not implement `Qux`
15 LL |     baz().await;
16    |          ^^^^^^ await occurs here, with `x` maybe used later
17 LL | }
18    | - `x` is later dropped here
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`
24
25 error: aborting due to previous error
26
27 For more information about this error, try `rustc --explain E0277`.