rust/tests/ui/mut_mutex_lock.stderr
2020-10-25 17:41:24 +08:00

12 lines
378 B
Plaintext

error: calling `&mut Mutex::lock` unnecessarily locks an exclusive (mutable) reference
--> $DIR/mut_mutex_lock.rs:9:21
|
LL | let mut value = value_mutex.lock().unwrap();
| ^^^^^^^^^^^^^^^^^^
|
= note: `-D clippy::mut-mutex-lock` implied by `-D warnings`
= help: use `&mut Mutex::get_mut` instead
error: aborting due to previous error