1 error[E0507]: cannot move out of `val`, a captured variable in an `FnMut` closure
2 --> $DIR/issue-87456-point-to-closure.rs:10:28
4 LL | let val = String::new();
5 | --- captured outer variable
8 | -- captured by this `FnMut` closure
10 LL | let _foo: String = val;
11 | ^^^ move occurs because `val` has type `String`, which does not implement the `Copy` trait
13 help: consider borrowing here
15 LL | let _foo: String = &val;
18 error: aborting due to previous error
20 For more information about this error, try `rustc --explain E0507`.