style: Remove dead and unsafe code.

MozReview-Commit-ID: 9seuLNCJAqz
This commit is contained in:
Emilio Cobos Álvarez 2018-05-25 00:51:43 +02:00
parent 8f367be650
commit a360dbf98d
No known key found for this signature in database
GPG key ID: 056B727BB9C1027C

View file

@ -13,13 +13,6 @@ impl<T> nsCOMPtr<T> {
pub fn raw<U>(&self) -> *mut T {
self.mRawPtr
}
/// Set this pointer from an addrefed raw pointer.
/// It leaks the old pointer.
#[inline]
pub unsafe fn set_raw_from_addrefed<U>(&mut self, ptr: *mut T) {
self.mRawPtr = ptr;
}
}
#[cfg(not(feature = "gecko_debug"))]
@ -29,11 +22,4 @@ impl nsCOMPtr {
pub fn raw<T>(&self) -> *mut T {
self._base.mRawPtr as *mut _
}
/// Set this pointer from an addrefed raw pointer.
/// It leaks the old pointer.
#[inline]
pub unsafe fn set_raw_from_addrefed<T>(&mut self, ptr: *mut T) {
self._base.mRawPtr = ptr as *mut _;
}
}