aboutsummaryrefslogtreecommitdiff
path: root/src/export.rs
diff options
context:
space:
mode:
authorJorge Aparicio <jorge@japaric.io>2019-05-21 14:18:43 +0200
committerJorge Aparicio <jorge@japaric.io>2019-05-21 14:18:43 +0200
commitfafc94ccfba4447c9eba7457a977d67a74507436 (patch)
treea413815ad51321d88521daad79b818805f40b2b9 /src/export.rs
parent6acb156482f8dfeba6348f05ac231727906c138d (diff)
removes the maybe_uninit feature gate
and stop newtyping `core::mem::MaybeUninit`
Diffstat (limited to 'src/export.rs')
-rw-r--r--src/export.rs30
1 files changed, 0 insertions, 30 deletions
diff --git a/src/export.rs b/src/export.rs
index 93a92fc..ee4df52 100644
--- a/src/export.rs
+++ b/src/export.rs
@@ -68,36 +68,6 @@ impl Priority {
}
}
-// We newtype `core::mem::MaybeUninit` so the end-user doesn't need `#![feature(maybe_uninit)]` in
-// their code
-pub struct MaybeUninit<T> {
- inner: core::mem::MaybeUninit<T>,
-}
-
-impl<T> MaybeUninit<T> {
- pub const fn uninit() -> Self {
- MaybeUninit {
- inner: core::mem::MaybeUninit::uninit(),
- }
- }
-
- pub fn as_ptr(&self) -> *const T {
- self.inner.as_ptr()
- }
-
- pub fn as_mut_ptr(&mut self) -> *mut T {
- self.inner.as_mut_ptr()
- }
-
- pub unsafe fn read(&self) -> T {
- self.inner.read()
- }
-
- pub fn write(&mut self, value: T) -> &mut T {
- self.inner.write(value)
- }
-}
-
#[inline(always)]
pub fn assert_send<T>()
where