Struct safer_ffi::slice::slice_raw_Layout
source · [−]#[repr(C)]pub struct slice_raw_Layout<T> where
NonNull<T>: ReprC,
usize: ReprC,
T: ReprC, {
pub ptr: <NonNull<T> as ReprC>::CLayout,
pub len: <usize as ReprC>::CLayout,
}
Fields
ptr: <NonNull<T> as ReprC>::CLayout
len: <usize as ReprC>::CLayout
Trait Implementations
sourceimpl<T> CType for slice_raw<T> where
<NonNull<T> as ReprC>::CLayout: CType,
<usize as ReprC>::CLayout: CType,
T: ReprC,
NonNull<T>: ReprC,
usize: ReprC,
T: ReprC,
impl<T> CType for slice_raw<T> where
<NonNull<T> as ReprC>::CLayout: CType,
<usize as ReprC>::CLayout: CType,
T: ReprC,
NonNull<T>: ReprC,
usize: ReprC,
T: ReprC,
sourcefn c_short_name_fmt(fmt: &mut Formatter<'_>) -> Result
fn c_short_name_fmt(fmt: &mut Formatter<'_>) -> Result
A short-name description of the type, mainly used to fill “placeholders” such as when monomorphising generics structs or arrays. Read more
sourcefn c_define_self(definer: &mut dyn Definer) -> Result<()>
fn c_define_self(definer: &mut dyn Definer) -> Result<()>
Necessary one-time code for CType::c_var
()
to make sense. Read more
sourcefn c_var_fmt(fmt: &mut Formatter<'_>, var_name: &str) -> Result
fn c_var_fmt(fmt: &mut Formatter<'_>, var_name: &str) -> Result
The core method of the trait: it provides the implementation to be
used by CType::c_var
, by bringing a Formatter
in scope. Read more
type OPAQUE_KIND = Concrete
sourcefn c_short_name() -> ImplDisplay<Self>
fn c_short_name() -> ImplDisplay<Self>
impl<T> Copy for slice_raw<T> where
NonNull<T>: ReprC,
usize: ReprC,
T: ReprC,
Auto Trait Implementations
impl<T> !RefUnwindSafe for slice_raw<T>
impl<T> !Send for slice_raw<T>
impl<T> !Sync for slice_raw<T>
impl<T> !Unpin for slice_raw<T>
impl<T> !UnwindSafe for slice_raw<T>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ManuallyDropMut for T
impl<T> ManuallyDropMut for T
type Ret = ManuallyDrop<T>
fn manually_drop_mut(&'__ mut self) -> &'__ mut ManuallyDrop<T>
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more