Closed
Description
use futures::future::{FutureExt, LocalBoxFuture}; // 0.3.1
async fn plain() {}
fn boxed() -> LocalBoxFuture<'static, ()> {
async {}.boxed_local()
}
pub async fn example() {
plain();
boxed();
}
warning: unused implementer of `core::future::future::Future` that must be used
--> src/lib.rs:10:5
|
10 | plain();
| ^^^^^^^^
|
= note: `#[warn(unused_must_use)]` on by default
= note: futures do nothing unless you `.await` or poll them
Sadly, there's no error for the unused result of boxed
, which has already caused me a few minutes of head-scratching and debugging.
Metadata
Metadata
Assignees
Labels
No labels