#[non_exhaustive]#[repr(C)]pub struct UnionType<'shape> {
pub repr: Repr,
pub fields: &'shape [Field<'shape>],
}Expand description
Common fields for union types
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.repr: ReprRepresentation of the union’s data
fields: &'shape [Field<'shape>]all fields
Trait Implementations§
impl<'shape> Copy for UnionType<'shape>
impl<'shape> Eq for UnionType<'shape>
impl<'shape> StructuralPartialEq for UnionType<'shape>
Auto Trait Implementations§
impl<'shape> Freeze for UnionType<'shape>
impl<'shape> RefUnwindSafe for UnionType<'shape>
impl<'shape> Send for UnionType<'shape>
impl<'shape> Sync for UnionType<'shape>
impl<'shape> Unpin for UnionType<'shape>
impl<'shape> UnwindSafe for UnionType<'shape>
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