Closure capture borrow diagnostics for disjoint captures
This commit is contained in:
parent
6e2a34474b
commit
08c4fbcea7
56 changed files with 532 additions and 152 deletions
|
|
@ -7,7 +7,7 @@ LL |
|
|||
LL | let x = move || {
|
||||
| ^^^^^^^ move out of `fancy_num` occurs here
|
||||
LL | println!("child function: {}", fancy_num.num);
|
||||
| --------- move occurs due to use in closure
|
||||
| ------------- move occurs due to use in closure
|
||||
...
|
||||
LL | println!("main function: {}", fancy_ref.num);
|
||||
| ------------- borrow later used here
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue