File tree 2 files changed +22
-18
lines changed
2 files changed +22
-18
lines changed Original file line number Diff line number Diff line change @@ -7,17 +7,19 @@ error[E0499]: cannot borrow `c.shared` as mutable more than once at a time
7
7
| _________| first borrow later used by call
8
8
| |
9
9
21 | | c.shared.lock(|_| {}); // borrow error
10
- | | -------- first borrow occurs due to use of `c` in closure
10
+ | | -------- first borrow occurs due to use of `c.shared ` in closure
11
11
22 | | });
12
12
| |__________^ second mutable borrow occurs here
13
13
14
- error[E0499]: cannot borrow `c` as mutable more than once at a time
14
+ error[E0499]: cannot borrow `c.shared ` as mutable more than once at a time
15
15
--> ui/lockall_borrow_shared.rs:20:23
16
16
|
17
- 20 | c.shared.lock(|_| {
18
- | -------- ---- ^^^ second mutable borrow occurs here
19
- | | |
20
- | | first borrow later used by call
21
- | first mutable borrow occurs here
22
- 21 | c.shared.lock(|_| {}); // borrow error
23
- | -------- second borrow occurs due to use of `c` in closure
17
+ 20 | c.shared.lock(|_| {
18
+ | - ---- ^^^ second mutable borrow occurs here
19
+ | | |
20
+ | _________| first borrow later used by call
21
+ | |
22
+ 21 | | c.shared.lock(|_| {}); // borrow error
23
+ | | -------- second borrow occurs due to use of `c.shared` in closure
24
+ 22 | | });
25
+ | |__________- first mutable borrow occurs here
Original file line number Diff line number Diff line change @@ -7,17 +7,19 @@ error[E0499]: cannot borrow `c.shared` as mutable more than once at a time
7
7
| _________| first borrow later used by call
8
8
| |
9
9
21 | | c.shared.a.lock(|_| {}); // borrow error
10
- | | ---------- first borrow occurs due to use of `c` in closure
10
+ | | ---------- first borrow occurs due to use of `c.shared.a ` in closure
11
11
22 | | });
12
12
| |__________^ second mutable borrow occurs here
13
13
14
- error[E0499]: cannot borrow `c` as mutable more than once at a time
14
+ error[E0499]: cannot borrow `c.shared.a ` as mutable more than once at a time
15
15
--> ui/lockall_borrow_shared_a.rs:20:23
16
16
|
17
- 20 | c.shared.lock(|_| {
18
- | -------- ---- ^^^ second mutable borrow occurs here
19
- | | |
20
- | | first borrow later used by call
21
- | first mutable borrow occurs here
22
- 21 | c.shared.a.lock(|_| {}); // borrow error
23
- | ---------- second borrow occurs due to use of `c` in closure
17
+ 20 | c.shared.lock(|_| {
18
+ | - ---- ^^^ second mutable borrow occurs here
19
+ | | |
20
+ | _________| first borrow later used by call
21
+ | |
22
+ 21 | | c.shared.a.lock(|_| {}); // borrow error
23
+ | | ---------- second borrow occurs due to use of `c.shared.a` in closure
24
+ 22 | | });
25
+ | |__________- first mutable borrow occurs here
You can’t perform that action at this time.
0 commit comments