]> git.lizzy.rs Git - rust.git/blob - src/test/ui/async-await/async-error-span.rs
Rollup merge of #71627 - ldm0:autoderefarg, r=Dylan-DPC
[rust.git] / src / test / ui / async-await / async-error-span.rs
1 // edition:2018
2
3 // Regression test for issue #62382.
4
5 use std::future::Future;
6
7 fn get_future() -> impl Future<Output = ()> {
8 //~^ ERROR the trait bound `(): std::future::Future` is not satisfied
9     panic!()
10 }
11
12 async fn foo() {
13     let a; //~ ERROR type inside `async fn` body must be known in this context
14     get_future().await;
15 }
16
17 fn main() {}