remove "#" symbols to make the code compile

This commit is contained in:
Kaiyin Zhong 2016-04-15 00:51:20 +02:00
parent 073a09fd63
commit f91649144e

View File

@ -492,12 +492,12 @@ fn factory() -> Box<Fn(i32) -> i32> {
Box::new(move |x| x + num)
}
# fn main() {
fn main() {
let f = factory();
let answer = f(1);
assert_eq!(6, answer);
# }
}
```
By making the inner closure a `move Fn`, we create a new stack frame for our