We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0d82fb5 commit 1792ef6Copy full SHA for 1792ef6
src/doc/trpl/closures.md
@@ -120,7 +120,7 @@ let y = &mut num;
120
```
121
122
If your closure requires it, however, Rust will take ownership and move
123
-the environment instead:
+the environment instead. This doesn’t work:
124
125
```rust,ignore
126
let nums = vec![1, 2, 3];
@@ -130,7 +130,7 @@ let takes_nums = || nums;
130
println!("{:?}", nums);
131
132
133
-This gives us:
+We get this error:
134
135
```text
136
note: `nums` moved into closure environment here because it has type
0 commit comments