rust/tests/ui/dropck/coroutine-liveness-1.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
296 B
Rust
Raw Normal View History

2023-11-02 11:24:00 -05:00
//@ check-pass
//@ edition: 2021
// regression test for #116242.
use std::future;
fn main() {
let mut recv = future::ready(());
let _combined_fut = async {
let _ = || read(&mut recv);
};
drop(recv);
}
fn read<F: future::Future>(_: &mut F) -> F::Output {
todo!()
}