fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #71365 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4fb7144ed15

1.43.0
453 B13 linesraw
1error[E0505]: cannot move out of `a` because it is borrowed
2  --> $DIR/drop-with-active-borrows-1.rs:4:10
3   |
4LL |     let b: Vec<&str> = a.lines().collect();
5   |                        - borrow of `a` occurs here
6LL |     drop(a);
7   |          ^ move out of `a` occurs here
8LL |     for s in &b {
9   |              -- borrow later used here
10
11error: aborting due to previous error
12
13For more information about this error, try `rustc --explain E0505`.