summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/await_holding_lock.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:02:58 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:02:58 +0000
commit698f8c2f01ea549d77d7dc3338a12e04c11057b9 (patch)
tree173a775858bd501c378080a10dca74132f05bc50 /src/tools/clippy/tests/ui/await_holding_lock.stderr
parentInitial commit. (diff)
downloadrustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.tar.xz
rustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.zip
Adding upstream version 1.64.0+dfsg1.upstream/1.64.0+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/tools/clippy/tests/ui/await_holding_lock.stderr')
-rw-r--r--src/tools/clippy/tests/ui/await_holding_lock.stderr208
1 files changed, 208 insertions, 0 deletions
diff --git a/src/tools/clippy/tests/ui/await_holding_lock.stderr b/src/tools/clippy/tests/ui/await_holding_lock.stderr
new file mode 100644
index 000000000..976da8d92
--- /dev/null
+++ b/src/tools/clippy/tests/ui/await_holding_lock.stderr
@@ -0,0 +1,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
+