19 lines
706 B
Plaintext
19 lines
706 B
Plaintext
|
error[E0499]: cannot borrow `a` as mutable more than once at a time
|
||
|
--> $DIR/feature-gate-if-let-rescope.rs:24:9
|
||
|
|
|
||
|
LL | if let None = a.f().as_ref() {
|
||
|
| -----
|
||
|
| |
|
||
|
| first mutable borrow occurs here
|
||
|
| a temporary with access to the first borrow is created here ...
|
||
|
...
|
||
|
LL | a.f().unwrap();
|
||
|
| ^ second mutable borrow occurs here
|
||
|
LL |
|
||
|
LL | };
|
||
|
| - ... and the first borrow might be used here, when that temporary is dropped and runs the destructor for type `Option<B<'_, A>>`
|
||
|
|
||
|
error: aborting due to 1 previous error
|
||
|
|
||
|
For more information about this error, try `rustc --explain E0499`.
|