summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-46471-1.rs
blob: aa161d40f702d5e7be4296e20a58f69c3a76d410 (plain)
1
2
3
4
5
6
7
8
fn main() {
    let y = {
        let mut z = 0;
        &mut z
    };
    //~^^ ERROR `z` does not live long enough [E0597]
    println!("{}", y);
}