pub struct Type<I: Layout> {
pub layout: I::TypeLayout,
pub annotations: Vec<Annotation>,
pub variant: TypeVariant<I>,
}
Expand description
A C type.
Fields§
§layout: I::TypeLayout
The layout of the type.
annotations: Vec<Annotation>
The annotations on this type.
variant: TypeVariant<I>
The variant of the type.
Implementations§
Source§impl<I: Layout> Type<I>
impl<I: Layout> Type<I>
Sourcepub fn into<J: Layout>(self) -> Type<J>where
I::TypeLayout: Into<J::TypeLayout>,
I::FieldLayout: Into<J::FieldLayout>,
I::OpaqueLayout: Into<J::OpaqueLayout>,
pub fn into<J: Layout>(self) -> Type<J>where
I::TypeLayout: Into<J::TypeLayout>,
I::FieldLayout: Into<J::FieldLayout>,
I::OpaqueLayout: Into<J::OpaqueLayout>,
Returns the identical type with the Layout
converted.
Trait Implementations§
impl<I: Eq + Layout> Eq for Type<I>where
I::TypeLayout: Eq,
impl<I: Layout> StructuralPartialEq for Type<I>
Auto Trait Implementations§
impl<I> Freeze for Type<I>
impl<I> RefUnwindSafe for Type<I>where
<I as Layout>::TypeLayout: RefUnwindSafe,
<I as Layout>::OpaqueLayout: RefUnwindSafe,
<I as Layout>::FieldLayout: RefUnwindSafe,
impl<I> Send for Type<I>where
<I as Layout>::TypeLayout: Send,
<I as Layout>::OpaqueLayout: Send,
<I as Layout>::FieldLayout: Send,
impl<I> Sync for Type<I>where
<I as Layout>::TypeLayout: Sync,
<I as Layout>::OpaqueLayout: Sync,
<I as Layout>::FieldLayout: Sync,
impl<I> Unpin for Type<I>where
<I as Layout>::TypeLayout: Unpin,
<I as Layout>::OpaqueLayout: Unpin,
<I as Layout>::FieldLayout: Unpin,
impl<I> UnwindSafe for Type<I>where
<I as Layout>::TypeLayout: UnwindSafe,
<I as Layout>::OpaqueLayout: UnwindSafe,
<I as Layout>::FieldLayout: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more