rust/tests/ui/async-await/async-error-span.rs

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

18 lines
278 B
Rust
Raw Normal View History

//@ edition:2018
2019-08-02 03:45:58 +02:00
// Regression test for issue #62382.
use std::future::Future;
fn get_future() -> impl Future<Output = ()> {
//~^ ERROR `()` is not a future
panic!()
}
async fn foo() {
2023-06-24 10:02:54 +00:00
let a; //~ ERROR type annotations needed
get_future().await;
}
fn main() {}