2024-01-25 17:43:35 +00:00
|
|
|
//@ edition:2021
|
2025-01-21 11:10:02 +00:00
|
|
|
//@ revisions: current next
|
|
|
|
//@ ignore-compare-mode-next-solver (explicit revisions)
|
|
|
|
//@[next] compile-flags: -Znext-solver
|
2024-01-25 17:43:35 +00:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
fn needs_fn(x: impl FnOnce()) {}
|
|
|
|
needs_fn(async || {});
|
2025-02-02 01:00:12 +00:00
|
|
|
//~^ ERROR expected `{async closure@is-not-fn.rs:8:14}` to return `()`
|
2024-01-25 17:43:35 +00:00
|
|
|
}
|