2024-01-26 18:50:31 -06:00
|
|
|
//@ compile-flags: -Zverbose-internals
|
|
|
|
//@ edition:2021
|
|
|
|
|
|
|
|
#![feature(async_closure)]
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let x = async || {};
|
|
|
|
//~^ NOTE the expected `async` closure body
|
|
|
|
let () = x();
|
|
|
|
//~^ ERROR mismatched types
|
2024-01-29 11:41:51 -06:00
|
|
|
//~| NOTE this expression has type `{static main::{closure#0}::{closure#0}<
|
2024-01-26 18:50:31 -06:00
|
|
|
//~| NOTE expected `async` closure body, found `()`
|
2024-01-29 11:41:51 -06:00
|
|
|
//~| NOTE expected `async` closure body `{static main::{closure#0}::{closure#0}<
|
2024-01-26 18:50:31 -06:00
|
|
|
}
|