Skip to content

Commit

Permalink
chore(header): fix unused_unsafe in internals
Browse files Browse the repository at this point in the history
  • Loading branch information
seanmonstar committed Jan 29, 2018
1 parent 1f8b354 commit a3f87c0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/header/internals/cell.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,10 @@ impl<V: ?Sized + Any + 'static> PtrMapCell<V> {

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

0 comments on commit a3f87c0

Please sign in to comment.