Flesh out a few more tests
This commit is contained in:
parent
2252ff7302
commit
c8e3f35eb6
4 changed files with 36 additions and 9 deletions
|
@ -8,11 +8,15 @@ extern crate block_on;
|
|||
|
||||
fn main() {
|
||||
block_on::block_on(async {
|
||||
let x = async || {};
|
||||
|
||||
async fn needs_async_fn_once(x: impl async FnOnce()) {
|
||||
x().await;
|
||||
}
|
||||
needs_async_fn_once(x).await;
|
||||
|
||||
needs_async_fn_once(async || {}).await;
|
||||
|
||||
needs_async_fn_once(|| async {}).await;
|
||||
|
||||
async fn foo() {}
|
||||
needs_async_fn_once(foo).await;
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue