Skip to content

Commit 819b4d5

Browse files
authored
Rollup merge of rust-lang#124266 - RalfJung:no-answer, r=joboet
remove an unused type from the reentrant lock tests At least it seems unused. This was added back in 45aa6c8 together with a test related to poisoning; when the test got removed, it seems like it was forgotten to also remove this type.
2 parents 8039488 + df437a2 commit 819b4d5

File tree

1 file changed

+1
-8
lines changed
  • library/std/src/sync/reentrant_lock

1 file changed

+1
-8
lines changed

library/std/src/sync/reentrant_lock/tests.rs

+1-8
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::{ReentrantLock, ReentrantLockGuard};
1+
use super::ReentrantLock;
22
use crate::cell::RefCell;
33
use crate::sync::Arc;
44
use crate::thread;
@@ -51,10 +51,3 @@ fn trylock_works() {
5151
.unwrap();
5252
let _lock3 = l.try_lock();
5353
}
54-
55-
pub struct Answer<'a>(pub ReentrantLockGuard<'a, RefCell<u32>>);
56-
impl Drop for Answer<'_> {
57-
fn drop(&mut self) {
58-
*self.0.borrow_mut() = 42;
59-
}
60-
}

0 commit comments

Comments
 (0)