rust/tests/ui/coroutine/static-closure-unexpanded.rs
2025-12-10 23:41:19 +00:00

10 lines
227 B
Rust

// Tests that static closures are not stable in the parser grammar unless the
// coroutine feature is enabled.
#[cfg(false)]
fn foo() {
let _ = static || {};
//~^ ERROR coroutine syntax is experimental
}
fn main() {}