mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-04 04:39:16 +00:00
12 lines
194 B
Rust
12 lines
194 B
Rust
//@ run-pass
|
|
#![allow(unused_mut)]
|
|
fn into_inner() -> [u64; 1024] {
|
|
let mut x = 10 + 20;
|
|
[x; 1024]
|
|
}
|
|
|
|
fn main(){
|
|
let x: &[u64] = &[30; 1024];
|
|
assert_eq!(&into_inner()[..], x);
|
|
}
|