diff --git a/src/fixed_width_ints.rs b/src/fixed_width_ints.rs index 1900833ff78f..93439f989c70 100644 --- a/src/fixed_width_ints.rs +++ b/src/fixed_width_ints.rs @@ -1,6 +1,7 @@ //! This module contains type aliases for C's fixed-width integer types . //! //! These aliases are deprecated: use the Rust types instead. +use crate::prelude::*; #[deprecated(since = "0.2.55", note = "Use i8 instead.")] pub type int8_t = i8; diff --git a/src/teeos/mod.rs b/src/teeos/mod.rs index a46587d11110..290ab8906232 100644 --- a/src/teeos/mod.rs +++ b/src/teeos/mod.rs @@ -4,11 +4,10 @@ //! when linking is explicitly requested. #![allow(non_camel_case_types)] #![allow(non_snake_case)] - // only supported on Rust > 1.59, so we can directly reexport c_void from core. pub use core::ffi::c_void; -use Option; +use crate::prelude::*; pub type c_schar = i8; diff --git a/src/unix/bsd/netbsdlike/netbsd/riscv64.rs b/src/unix/bsd/netbsdlike/netbsd/riscv64.rs index c823076e21f5..b5e72084d5aa 100644 --- a/src/unix/bsd/netbsdlike/netbsd/riscv64.rs +++ b/src/unix/bsd/netbsdlike/netbsd/riscv64.rs @@ -26,7 +26,7 @@ s_no_extra_traits! { } } -pub(crate) const _ALIGNBYTES: usize = crate::mem::size_of::() - 1; +pub(crate) const _ALIGNBYTES: usize = mem::size_of::() - 1; pub const PT_GETREGS: c_int = PT_FIRSTMACH + 0; pub const PT_SETREGS: c_int = PT_FIRSTMACH + 1; diff --git a/src/unix/bsd/netbsdlike/openbsd/arm.rs b/src/unix/bsd/netbsdlike/openbsd/arm.rs index 11305470d87b..1e66ed247a2e 100644 --- a/src/unix/bsd/netbsdlike/openbsd/arm.rs +++ b/src/unix/bsd/netbsdlike/openbsd/arm.rs @@ -4,6 +4,6 @@ pub type c_long = i32; pub type c_ulong = u32; pub type c_char = u8; -pub(crate) const _ALIGNBYTES: usize = crate::mem::size_of::() - 1; +pub(crate) const _ALIGNBYTES: usize = mem::size_of::() - 1; pub const _MAX_PAGE_SHIFT: u32 = 12; diff --git a/src/unix/bsd/netbsdlike/openbsd/powerpc64.rs b/src/unix/bsd/netbsdlike/openbsd/powerpc64.rs index 977eb840c90a..cb808719fb8e 100644 --- a/src/unix/bsd/netbsdlike/openbsd/powerpc64.rs +++ b/src/unix/bsd/netbsdlike/openbsd/powerpc64.rs @@ -1,3 +1,5 @@ +use crate::prelude::*; + pub type c_long = i64; pub type c_ulong = u64; pub type c_char = u8; diff --git a/src/unix/redox/mod.rs b/src/unix/redox/mod.rs index 748dc2f1d715..db854dd6300e 100644 --- a/src/unix/redox/mod.rs +++ b/src/unix/redox/mod.rs @@ -82,8 +82,7 @@ s_no_extra_traits! { pub struct sockaddr_storage { pub ss_family: crate::sa_family_t, - __ss_padding: - [u8; 128 - crate::mem::size_of::() - crate::mem::size_of::()], + __ss_padding: [u8; 128 - mem::size_of::() - mem::size_of::()], __ss_align: c_ulong, } }