Skip to content

Commit a3f87c0

Browse files
committed
chore(header): fix unused_unsafe in internals
1 parent 1f8b354 commit a3f87c0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/header/internals/cell.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,10 @@ impl<V: ?Sized + Any + 'static> PtrMapCell<V> {
9393

9494
#[inline]
9595
pub fn into_value(self, key: TypeId) -> Option<Box<V>> {
96+
// UnsafeCell::into_inner was unsafe forever, and 1.25 has removed
97+
// the unsafe modifier, resulting in a warning. This allow can be
98+
// removed when the minimum supported rust version is at least 1.25.
99+
#[allow(unused_unsafe)]
96100
let map = unsafe { self.0.into_inner() };
97101
match map {
98102
PtrMap::Empty => None,

0 commit comments

Comments
 (0)