rust/tests/pass/issues/issue-5917.rs
2022-06-20 16:09:45 -07:00

7 lines
132 B
Rust

struct T(&'static [isize]);
static STATIC: T = T(&[5, 4, 3]);
pub fn main() {
let T(ref v) = STATIC;
assert_eq!(v[0], 5);
}