mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-24 15:54:15 +00:00
9 lines
181 B
Rust
9 lines
181 B
Rust
// ignore-compare-mode-nll
|
|
|
|
#![allow(const_err)]
|
|
|
|
// nll successfully compiles this.
|
|
fn main() {
|
|
let x: &'static _ = &|| { let z = 3; z }; //~ ERROR does not live long enough
|
|
}
|