Searched refs:DstLayout (Results 1 – 7 of 7) sorted by relevance
| /linux/rust/zerocopy/src/ |
| H A D | layout.rs | 33 pub struct DstLayout { struct 105 impl DstLayout { implementation 185 pub const fn new_zst(repr_align: Option<NonZeroUsize>) -> DstLayout { in new_zst() argument 193 DstLayout { in new_zst() 209 pub const fn for_type<T>() -> DstLayout { in for_type() argument 214 DstLayout { in for_type() 233 pub const fn for_unpadded_type<T>() -> DstLayout { in for_unpadded_type() argument 242 pub(crate) const fn for_slice<T>() -> DstLayout { in for_slice() argument 251 DstLayout { in for_slice() 283 fields: &[DstLayout], in for_repr_c_struct() argument [all …]
|
| H A D | lib.rs | 797 const LAYOUT: DstLayout; 929 DstLayout::MAX_SIZE, in maximum_trailing_slice_len() 969 fn size_for_metadata(self, layout: DstLayout) -> Option<usize>; in size_for_metadata() 983 fn size_for_metadata(self, layout: DstLayout) -> Option<usize> { in size_for_metadata() 1005 fn size_for_metadata(self, layout: DstLayout) -> Option<usize> { in size_for_metadata() 1063 const LAYOUT: DstLayout = DstLayout::for_slice::<T>(); 6511 |offset, align, trailing_slice_elem_size, statically_shallow_unpadded| DstLayout { in test_known_layout() 6585 let sized_layout = |align, size| DstLayout { in test_known_layout_derive() 6591 let unsized_layout = |align, elem_size, offset, statically_shallow_unpadded| DstLayout { in test_known_layout_derive() 6603 let expected = DstLayout::for_type::<KL01>(); in test_known_layout_derive() [all …]
|
| H A D | byte_slice.rs | 370 kani::assume(len <= crate::DstLayout::MAX_SIZE); in any_vec()
|
| /linux/rust/zerocopy-derive/derive/ |
| H A D | known_layout.rs | 112 … const LAYOUT: #zerocopy_crate::DstLayout = #zerocopy_crate::DstLayout::for_repr_c_struct( in derive_known_layout_for_repr_c_struct() 116 #(#zerocopy_crate::DstLayout::for_type::<#leading_fields_tys>(),)* in derive_known_layout_for_repr_c_struct() 240 …const LAYOUT: #zerocopy_crate::DstLayout = <#ident #ty_generics as #zerocopy_crate::KnownLayout>::… in derive_known_layout_for_repr_c_struct() 289 … const LAYOUT: #zerocopy_crate::DstLayout = #zerocopy_crate::DstLayout::for_type::<Self>(); in derive()
|
| /linux/rust/zerocopy/src/util/ |
| H A D | macros.rs | 459 const LAYOUT: crate::DstLayout = crate::DstLayout::for_type::<$ty>(); 505 const LAYOUT: DstLayout = <$repr as KnownLayout>::LAYOUT;
|
| H A D | mod.rs | 147 kani::requires(len <= DstLayout::MAX_SIZE), 614 DstLayout { in validate_cast_and_convert_metadata()
|
| H A D | macro_util.rs | 351 let layout = $crate::DstLayout::for_repr_c_struct( 362 $crate::DstLayout::for_unpadded_type::<$t>() 368 $crate::DstLayout::for_unpadded_type::<$t>()
|