mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-02 15:32:06 +00:00
65 lines
1.4 KiB
Plaintext
65 lines
1.4 KiB
Plaintext
error: unused implementer of `Future` that must be used
|
|
--> $DIR/unused-async.rs:31:5
|
|
|
|
|
LL | foo();
|
|
| ^^^^^
|
|
|
|
|
= note: futures do nothing unless you `.await` or poll them
|
|
note: the lint level is defined here
|
|
--> $DIR/unused-async.rs:2:9
|
|
|
|
|
LL | #![deny(unused_must_use)]
|
|
| ^^^^^^^^^^^^^^^
|
|
|
|
error: unused return value of `foo` that must be used
|
|
--> $DIR/unused-async.rs:31:5
|
|
|
|
|
LL | foo();
|
|
| ^^^^^
|
|
|
|
|
help: use `let _ = ...` to ignore the resulting value
|
|
|
|
|
LL | let _ = foo();
|
|
| +++++++
|
|
|
|
error: unused output of future returned by `foo` that must be used
|
|
--> $DIR/unused-async.rs:33:5
|
|
|
|
|
LL | foo().await;
|
|
| ^^^^^^^^^^^
|
|
|
|
|
help: use `let _ = ...` to ignore the resulting value
|
|
|
|
|
LL | let _ = foo().await;
|
|
| +++++++
|
|
|
|
error: unused implementer of `Future` that must be used
|
|
--> $DIR/unused-async.rs:34:5
|
|
|
|
|
LL | bar();
|
|
| ^^^^^
|
|
|
|
|
= note: futures do nothing unless you `.await` or poll them
|
|
|
|
error: unused return value of `bar` that must be used
|
|
--> $DIR/unused-async.rs:34:5
|
|
|
|
|
LL | bar();
|
|
| ^^^^^
|
|
|
|
|
help: use `let _ = ...` to ignore the resulting value
|
|
|
|
|
LL | let _ = bar();
|
|
| +++++++
|
|
|
|
error: unused implementer of `Future` that must be used
|
|
--> $DIR/unused-async.rs:37:5
|
|
|
|
|
LL | baz();
|
|
| ^^^^^
|
|
|
|
|
= note: futures do nothing unless you `.await` or poll them
|
|
|
|
error: aborting due to 6 previous errors
|
|
|