Searched refs:Zeroable (Results 1 – 13 of 13) sorted by relevance
| /linux/rust/pin-init/src/ |
| H A D | lib.rs | 419 pub use ::pin_init_internal::Zeroable; 1532 pub unsafe trait Zeroable { interface 1580 pub fn init_zeroed<T: Zeroable>() -> impl Init<T> { in init_zeroed() 1615 pub const fn zeroed<T: Zeroable>() -> T { in zeroed() 1623 $(unsafe impl$($($generics)*)? Zeroable for $t {})* 1649 {<T: ?Sized + Zeroable>} UnsafeCell<T>, 1665 {<const N: usize, T: Zeroable>} [T; N], {<T: Zeroable>} Wrapping<T>, 1673 unsafe impl<$first: Zeroable> Zeroable for ($first,) {} impl 1678 unsafe impl<$first: Zeroable, $($t: Zeroable),*> Zeroable for ($first, $($t),*) {} impl 1694 unsafe impl<T: ZeroableOption> Zeroable for Option<T> {}
|
| H A D | macros.rs | |
| /linux/rust/bindings/ |
| H A D | lib.rs | 37 use pin_init::{MaybeZeroable, Zeroable}; 48 unsafe impl<Storage> Zeroable for __BindgenBitfieldUnit<Storage> where Storage: Zeroable {}
|
| /linux/rust/macros/ |
| H A D | zeroable.rs | |
| /linux/rust/pin-init/internal/src/ |
| H A D | zeroable.rs | 17 return Err(dcx.error(data_enum.enum_token, "cannot derive `Zeroable` for an enum")); in parse_zeroable_derive_input() 23 param.bounds.insert(0, parse_quote!(::pin_init::Zeroable)); in parse_zeroable_derive_input() 28 // SAFETY: Every field type implements `Zeroable` and padding bytes may be zero. in parse_zeroable_derive_input() 30 unsafe impl #impl_gen ::pin_init::Zeroable for #name #ty_gen in parse_zeroable_derive_input() 34 fn assert_zeroable<T: ?::core::marker::Sized + ::pin_init::Zeroable>() {} in parse_zeroable_derive_input() 54 return Err(dcx.error(data_enum.enum_token, "cannot derive `Zeroable` for an enum")); in parse_zeroable_derive_input() 60 param.bounds.insert(0, parse_quote!(::pin_init::Zeroable)); in parse_zeroable_derive_input() 68 .push(parse_quote!(#ty: for<'__dummy> ::pin_init::Zeroable)); in parse_zeroable_derive_input() 72 // SAFETY: Every field type implements `Zeroable` and padding bytes may be zero. in parse_zeroable_derive_input() 74 unsafe impl #impl_gen ::pin_init::Zeroable fo in parse_zeroable_derive_input() [all...] |
| H A D | lib.rs | 37 #[proc_macro_derive(Zeroable)] in pin_data()
|
| H A D | init.rs | 123 // The user specified `..Zeroable::zeroed()` at the end of the list of fields. 124 // Therefore we check if the struct implements `Zeroable` and then zero the memory. 128 where T: ::pin_init::Zeroable 130 // Ensure that the struct is indeed `Zeroable`. 132 // SAFETY: The type implements `Zeroable` by the check above. 197 && segments[0].ident == "Zeroable" 210 "expected nothing or `..Zeroable::init_zeroed()`.",
|
| /linux/rust/kernel/ |
| H A D | types.rs | 12 use pin_init::{PinInit, Wrapper, Zeroable}; 338 unsafe impl<T> Zeroable for Opaque<T> {} in new()
|
| H A D | prelude.rs | 60 Zeroable, //
|
| H A D | bitfield.rs | 334 unsafe impl ::pin_init::Zeroable for $name {} 556 use pin_init::Zeroable;
|
| H A D | uaccess.rs | 24 #[derive(Copy, Clone, Zeroable)]
|
| /linux/rust/kernel/num/ |
| H A D | bounded.rs | 1126 T: Integer<Signedness = Unsigned> + Zeroable, 1129 value.get() != Zeroable::zeroed() in from() 1148 T: Integer<Signedness = Unsigned> + Zeroable,
|
| /linux/rust/ |
| H A D | bindgen_parameters | 71 # Structs should implement `Zeroable` when all of their fields do.
|