]> git.proxmox.com Git - rustc.git/blame - src/test/ui/async-await/unnecessary-await.stderr
New upstream version 1.65.0+dfsg1
[rustc.git] / src / test / ui / async-await / unnecessary-await.stderr
CommitLineData
a2a8927a
XL
1error[E0277]: `()` is not a future
2 --> $DIR/unnecessary-await.rs:9:10
3 |
4LL | boo().await;
5 | -----^^^^^^ `()` is not a future
6 | |
7 | this call returns `()`
8 |
9 = help: the trait `Future` is not implemented for `()`
10 = note: () must be a future or must implement `IntoFuture` to be awaited
f2b60f7d 11 = note: required for `()` to implement `IntoFuture`
a2a8927a
XL
12help: remove the `.await`
13 |
14LL - boo().await;
15LL + boo();
923072b8 16 |
a2a8927a
XL
17help: alternatively, consider making `fn boo` asynchronous
18 |
19LL | async fn boo() {}
20 | +++++
21
22error: aborting due to previous error
23
24For more information about this error, try `rustc --explain E0277`.