2011-09-12 05:39:38 -05:00
|
|
|
fn test(-foo: @[int]) { assert (foo[0] == 10); }
|
2011-08-09 19:56:26 -05:00
|
|
|
|
|
|
|
fn main() {
|
2011-08-19 17:16:48 -05:00
|
|
|
let x = @[10];
|
2011-08-09 19:56:26 -05:00
|
|
|
// Test forgetting a local by move-in
|
|
|
|
test(x);
|
|
|
|
|
|
|
|
// Test forgetting a temporary by move-in.
|
2011-08-19 17:16:48 -05:00
|
|
|
test(@[10]);
|
2011-08-09 19:56:26 -05:00
|
|
|
}
|