2018-04-06 15:00:45 -04:00
|
|
|
error[E0499]: cannot borrow `foo` as mutable more than once at a time
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/two-phase-multi-mut.rs:13:5
|
2018-04-06 15:00:45 -04:00
|
|
|
|
|
|
|
|
LL | foo.method(&mut foo);
|
2018-09-29 11:47:47 +01:00
|
|
|
| ^^^^------^--------^
|
|
|
|
| | | |
|
|
|
|
| | | first mutable borrow occurs here
|
|
|
|
| | first borrow later used by call
|
2018-07-31 14:36:50 +02:00
|
|
|
| second mutable borrow occurs here
|
2018-04-06 15:00:45 -04:00
|
|
|
|
|
|
|
error[E0499]: cannot borrow `foo` as mutable more than once at a time
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/two-phase-multi-mut.rs:13:16
|
2018-04-06 15:00:45 -04:00
|
|
|
|
|
|
|
|
LL | foo.method(&mut foo);
|
2018-09-29 11:47:47 +01:00
|
|
|
| --- ------ ^^^^^^^^ second mutable borrow occurs here
|
|
|
|
| | |
|
|
|
|
| | first borrow later used by call
|
2018-07-31 14:36:50 +02:00
|
|
|
| first mutable borrow occurs here
|
2018-04-06 15:00:45 -04:00
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0499`.
|