summaryrefslogtreecommitdiffstats
path: root/tests/ui/mir/mir_codegen_array_2.rs
blob: 03d3aa5ade6319f9583a107fe3204d3d9b2b5be3 (plain)
1
2
3
4
5
6
7
8
9
// run-pass
fn into_inner(x: u64) -> [u64; 1024] {
    [x; 2*4*8*16]
}

fn main(){
    let x: &[u64] = &[42; 1024];
    assert_eq!(&into_inner(42)[..], x);
}