rust/src/test/run-pass/borrowck-fixed-length-vecs.rs

6 lines
72 B
Rust
Raw Normal View History

2012-06-14 18:27:44 -05:00
fn main() {
2012-10-09 23:28:04 -05:00
let x = [22];
2012-06-14 18:27:44 -05:00
let y = &x[0];
assert *y == 22;
2012-10-09 23:28:04 -05:00
}