rust/tests/ui/nll/mir_check_cast_unsize.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

11 lines
162 B
Rust
Raw Normal View History

2017-11-30 13:09:27 -06:00
#![allow(dead_code)]
use std::fmt::Debug;
fn bar<'a>(x: &'a u32) -> &'static dyn Debug {
x
2018-12-11 15:49:40 -06:00
//~^ ERROR lifetime may not live long enough
2017-11-30 13:09:27 -06:00
}
fn main() {}