rust/tests/ui/issues/issue-5884.rs

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

19 lines
258 B
Rust
Raw Normal View History

//@ build-pass
#![allow(dead_code)]
//@ pretty-expanded FIXME #23616
pub struct Foo {
a: isize,
}
struct Bar<'a> {
a: Box<Option<isize>>,
b: &'a Foo,
}
2014-10-02 05:10:09 +00:00
fn check(a: Box<Foo>) {
let _ic = Bar{ b: &*a, a: Box::new(None) };
}
pub fn main(){}