1 error: captured variable cannot escape `FnMut` closure body
2 --> $DIR/do-not-suggest-adding-move-when-closure-is-already-marked-as-move.rs:6:9
4 LL | let mut vec: Vec<i32> = Vec::new();
5 | ------- variable defined here
6 LL | let closure = move || {
7 | - inferred to be a `FnMut` closure
9 | --- variable captured here
10 LL | let mut iter = vec.iter();
11 LL | move || { iter.next() }
12 | ^^^^^^^^^^^^^^^^^^^^^^^ returns a closure that contains a reference to a captured variable, which then escapes the closure body
14 = note: `FnMut` closures only have access to their captured variables while they are executing...
15 = note: ...therefore, they cannot allow references to captured variables to escape
17 error: aborting due to previous error