2012-04-20 14:11:55 -05:00
|
|
|
// xfail-test
|
2012-04-24 17:52:52 -05:00
|
|
|
|
2012-06-29 18:26:56 -05:00
|
|
|
fn foo(x: &[int]) -> int {
|
2012-04-20 14:11:55 -05:00
|
|
|
x[0]
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
2012-10-09 23:28:04 -05:00
|
|
|
let p = [1,2,3,4,5];
|
2012-04-20 14:11:55 -05:00
|
|
|
assert foo(p) == 1;
|
|
|
|
}
|