mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-29 18:23:49 +00:00
18 lines
278 B
Rust
18 lines
278 B
Rust
//@ edition:2018
|
|
|
|
// Regression test for issue #62382.
|
|
|
|
use std::future::Future;
|
|
|
|
fn get_future() -> impl Future<Output = ()> {
|
|
//~^ ERROR `()` is not a future
|
|
panic!()
|
|
}
|
|
|
|
async fn foo() {
|
|
let a; //~ ERROR type annotations needed
|
|
get_future().await;
|
|
}
|
|
|
|
fn main() {}
|