2012-07-09 13:56:47 -04:00
|
|
|
// error-pattern:moving out of captured outer immutable variable in a stack closure
|
2012-03-17 14:39:15 -07:00
|
|
|
fn test(-x: uint) {}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let i = 3u;
|
2012-06-30 16:19:07 -07:00
|
|
|
for uint::range(0u, 10u) |_x| {test(i)}
|
2012-06-15 12:24:12 -07:00
|
|
|
}
|