Skip to content

Commit 0ccb600

Browse files
committed
Remove RwLock::clone_guard.
It's unused.
1 parent eeb5b78 commit 0ccb600

File tree

1 file changed

+0
-12
lines changed
  • compiler/rustc_data_structures/src

1 file changed

+0
-12
lines changed

compiler/rustc_data_structures/src/sync.rs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -578,18 +578,6 @@ impl<T> RwLock<T> {
578578
self.write()
579579
}
580580

581-
#[cfg(not(parallel_compiler))]
582-
#[inline(always)]
583-
pub fn clone_guard<'a>(rg: &ReadGuard<'a, T>) -> ReadGuard<'a, T> {
584-
ReadGuard::clone(rg)
585-
}
586-
587-
#[cfg(parallel_compiler)]
588-
#[inline(always)]
589-
pub fn clone_guard<'a>(rg: &ReadGuard<'a, T>) -> ReadGuard<'a, T> {
590-
ReadGuard::rwlock(&rg).read()
591-
}
592-
593581
#[cfg(not(parallel_compiler))]
594582
#[inline(always)]
595583
pub fn leak(&self) -> &T {

0 commit comments

Comments
 (0)