about summary refs log tree commit diff
path: root/tests/ui/issues/issue-31267.rs
blob: d6081bb87439f96951bc2e0a41cdb5b9f11c5c30 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//@ run-pass
// Regression test for issue #31267


struct Foo;

impl Foo {
    const FOO: [i32; 3] = [0; 3];
}

pub fn main() {
    let foo = Foo::FOO;
    assert_eq!(foo, [0i32, 0, 0]);
}