[][src]Trait libffi::high::types::CType

pub unsafe trait CType: Copy {
    fn reify() -> Type<Self>;
}

Types that we can automatically marshall to/from C.

In particular, for any type T that implements CType, we can get a Type<T> for describing that type. This trait is unsafe to implement because if the libffi type associated with a Rust type doesn’t match then we get undefined behavior.

Required methods

fn reify() -> Type<Self>

Creates or retrieves a Type<T> for any type T: CType.

We can use the resulting object to assemble a CIF to set up a call that uses type T.

Loading content...

Implementations on Foreign Types

impl CType for u8[src]

impl CType for i8[src]

impl CType for u16[src]

impl CType for i16[src]

impl CType for u32[src]

impl CType for i32[src]

impl CType for u64[src]

impl CType for i64[src]

impl CType for f32[src]

impl CType for f64[src]

impl CType for usize[src]

impl CType for isize[src]

impl CType for ()[src]

impl<T> CType for *const T[src]

impl<T> CType for *mut T[src]

Loading content...

Implementors

Loading content...