rustc/tests/ui/closures/binder/suggestion-for-introducing-lifetime-into-binder.rs
2023-08-02 10:33:26 +02:00

8 lines
221 B
Rust

#![feature(closure_lifetime_binder)]
fn main() {
for<> |_: &'a ()| -> () {};
//~^ ERROR use of undeclared lifetime name `'a`
for<'a> |_: &'b ()| -> () {};
//~^ ERROR use of undeclared lifetime name `'b`
}