fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0506]: cannot assign to `greeting` because it is borrowed 2 --> $DIR/issue-58776-borrowck-scans-children.rs:5:5 3 | 4LL | let res = (|| (|| &greeting)())(); 5 | -- -------- borrow occurs due to use in closure 6 | | 7 | `greeting` is borrowed here 8LL | 9LL | greeting = "DEALLOCATED".to_string(); 10 | ^^^^^^^^ `greeting` is assigned to here but it was already borrowed 11... 12LL | println!("thread result: {:?}", res); 13 | --- borrow later used here 14 15error: aborting due to previous error 16 17For more information about this error, try `rustc --explain E0506`.