mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-26 00:34:06 +00:00
17 lines
373 B
Rust
17 lines
373 B
Rust
// Test for ICE: cannot convert ReLateParam to a region vid
|
|
// https://github.com/rust-lang/rust/issues/125873
|
|
|
|
#![feature(closure_lifetime_binder)]
|
|
fn foo() {
|
|
let a = for<'a> |b: &'a ()| -> &'a () {
|
|
const {
|
|
let awd = ();
|
|
let _: &'a () = &awd;
|
|
//~^ `awd` does not live long enough
|
|
};
|
|
b
|
|
};
|
|
}
|
|
|
|
fn main() {}
|