-
Notifications
You must be signed in to change notification settings - Fork 13.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MIR-borrowck: Some minor fixes #46040
Conversation
@bors r+ |
📌 Commit 4beca6a has been approved by |
⌛ Testing commit 4beca6aad36086532078c205e97dad9d8526272e with merge 98e3158b7619099a2debf23ba36fa43af16e8f86... |
⌛ Testing commit 4beca6aad36086532078c205e97dad9d8526272e with merge 99559815fe2011b10892b9666aa4fbea548ddff3... |
💔 Test failed - status-travis |
UI test failure in error[E0502]: cannot borrow `*map` as mutable because it is also borrowed as immutable (Ast)
--> $DIR/get_default.rs:33:17
|
28 | match map.get() {
| --- immutable borrow occurs here
...
33 | map.set(String::new()); // Just AST errors here
| ^^^ mutable borrow occurs here
...
37 | }
| - immutable borrow ends here
error[E0502]: cannot borrow `*map` as mutable because it is also borrowed as immutable (Ast)
--> $DIR/get_default.rs:43:17
|
41 | match map.get() {
| --- immutable borrow occurs here
42 | Some(v) => {
43 | map.set(String::new()); // Both AST and MIR error here
| ^^^ mutable borrow occurs here
...
51 | }
| - immutable borrow ends here
error[E0502]: cannot borrow `*map` as mutable because it is also borrowed as immutable (Ast)
--> $DIR/get_default.rs:47:17
|
41 | match map.get() {
| --- immutable borrow occurs here
...
47 | map.set(String::new()); // Just AST errors here
| ^^^ mutable borrow occurs here
...
51 | }
| - immutable borrow ends here
-error[E0502]: cannot borrow `(*map)` as mutable because it is also borrowed as immutable (Mir)
+error[E0502]: cannot borrow `*map` as mutable because it is also borrowed as immutable (Mir)
--> $DIR/get_default.rs:43:17
|
41 | match map.get() {
| --- immutable borrow occurs here
42 | Some(v) => {
43 | map.set(String::new()); // Both AST and MIR error here
| ^^^ mutable borrow occurs here
error: aborting due to 4 previous errors |
@bors r+ |
📌 Commit 2285e35 has been approved by |
MIR-borrowck: Some minor fixes - Remove parens when printing dereference (fix #45185) - Change argument type of `autoderef` to `bool` - Change argument type of `field_index` to `Field`
☀️ Test successful - status-appveyor, status-travis |
autoderef
tobool
field_index
toField