]> git.proxmox.com Git - rustc.git/blob - src/test/ui/borrowck/issue-85581.stderr
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / borrowck / issue-85581.stderr
1 error[E0499]: cannot borrow `*heap` as mutable more than once at a time
2 --> $DIR/issue-85581.rs:9:22
3 |
4 LL | match heap.peek_mut() {
5 | ---------------
6 | |
7 | first mutable borrow occurs here
8 | a temporary with access to the first borrow is created here ...
9 LL | Some(_) => { heap.pop(); },
10 | ^^^^ second mutable borrow occurs here
11 ...
12 LL | }
13 | - ... and the first borrow might be used here, when that temporary is dropped and runs the destructor for type `Option<PeekMut<'_, i32>>`
14
15 error: aborting due to previous error
16
17 For more information about this error, try `rustc --explain E0499`.