summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/await_holding_lock.stderr
blob: 976da8d924247897317bed03461c579077a855cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:9:13
   |
LL |         let guard = x.lock().unwrap();
   |             ^^^^^
   |
   = note: `-D clippy::await-holding-lock` implied by `-D warnings`
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:9:9
   |
LL | /         let guard = x.lock().unwrap();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:24:13
   |
LL |         let guard = x.read().unwrap();
   |             ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:24:9
   |
LL | /         let guard = x.read().unwrap();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:29:13
   |
LL |         let mut guard = x.write().unwrap();
   |             ^^^^^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:29:9
   |
LL | /         let mut guard = x.write().unwrap();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:50:13
   |
LL |         let guard = x.lock().unwrap();
   |             ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:50:9
   |
LL | /         let guard = x.lock().unwrap();
LL | |
LL | |         let second = baz().await;
LL | |
...  |
LL | |         first + second + third
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:63:17
   |
LL |             let guard = x.lock().unwrap();
   |                 ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:63:13
   |
LL | /             let guard = x.lock().unwrap();
LL | |             baz().await
LL | |         };
   | |_________^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:75:17
   |
LL |             let guard = x.lock().unwrap();
   |                 ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:75:13
   |
LL | /             let guard = x.lock().unwrap();
LL | |             baz().await
LL | |         }
   | |_________^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:87:13
   |
LL |         let guard = x.lock();
   |             ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:87:9
   |
LL | /         let guard = x.lock();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:102:13
   |
LL |         let guard = x.read();
   |             ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:102:9
   |
LL | /         let guard = x.read();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:107:13
   |
LL |         let mut guard = x.write();
   |             ^^^^^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:107:9
   |
LL | /         let mut guard = x.write();
LL | |         baz().await
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:128:13
   |
LL |         let guard = x.lock();
   |             ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:128:9
   |
LL | /         let guard = x.lock();
LL | |
LL | |         let second = baz().await;
LL | |
...  |
LL | |         first + second + third
LL | |     }
   | |_____^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:141:17
   |
LL |             let guard = x.lock();
   |                 ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:141:13
   |
LL | /             let guard = x.lock();
LL | |             baz().await
LL | |         };
   | |_________^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:153:17
   |
LL |             let guard = x.lock();
   |                 ^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:153:13
   |
LL | /             let guard = x.lock();
LL | |             baz().await
LL | |         }
   | |_________^

error: this `MutexGuard` is held across an `await` point
  --> $DIR/await_holding_lock.rs:173:9
   |
LL |     let mut guard = x.lock().unwrap();
   |         ^^^^^^^^^
   |
   = help: consider using an async-aware `Mutex` type or ensuring the `MutexGuard` is dropped before calling await
note: these are all the `await` points this lock is held through
  --> $DIR/await_holding_lock.rs:173:5
   |
LL | /     let mut guard = x.lock().unwrap();
LL | |     *guard += 1;
LL | |     drop(guard);
LL | |     baz().await;
LL | | }
   | |_^

error: aborting due to 13 previous errors