Skip to main content

FromZeros

Trait FromZeros 

Source
pub unsafe trait FromZeros: TryFromBytes {
    // Provided methods
    fn zero(&mut self) { ... }
    fn new_zeroed() -> Self
       where Self: Sized { ... }
    fn new_box_zeroed() -> Result<Box<Self>, AllocError>
       where Self: Sized { ... }
    fn new_box_zeroed_with_elems(count: usize) -> Result<Box<Self>, AllocError>
       where Self: KnownLayout<PointerMetadata = usize> { ... }
    fn new_vec_zeroed(len: usize) -> Result<Vec<Self>, AllocError>
       where Self: Sized { ... }
    fn extend_vec_zeroed(
        v: &mut Vec<Self>,
        additional: usize,
    ) -> Result<(), AllocError>
       where Self: Sized { ... }
    fn insert_vec_zeroed(
        v: &mut Vec<Self>,
        position: usize,
        additional: usize,
    ) -> Result<(), AllocError>
       where Self: Sized { ... }
}
Expand description

Types for which a sequence of 0 bytes is a valid instance.

Any memory region of the appropriate length which is guaranteed to contain only zero bytes can be viewed as any FromZeros type with no runtime overhead. This is useful whenever memory is known to be in a zeroed state, such memory returned from some allocation routines.

§Warning: Padding bytes

Note that, when a value is moved or copied, only the non-padding bytes of that value are guaranteed to be preserved. It is unsound to assume that values written to padding bytes are preserved after a move or copy. For more details, see the FromBytes docs.

§Implementation

Do not implement this trait yourself! Instead, use #[derive(FromZeros)]; e.g.:

#[derive(FromZeros)]
struct MyStruct {
    ...
}

#[derive(FromZeros)]
#[repr(u8)]
enum MyEnum {
    ...
}

#[derive(FromZeros, Immutable)]
union MyUnion {
    ...
}

This derive performs a sophisticated, compile-time safety analysis to determine whether a type is FromZeros.

§Safety

This section describes what is required in order for T: FromZeros, and what unsafe code may assume of such types. If you don’t plan on implementing FromZeros manually, and you don’t plan on writing unsafe code that operates on FromZeros types, then you don’t need to read this section.

If T: FromZeros, then unsafe code may assume that it is sound to produce a T whose bytes are all initialized to zero. If a type is marked as FromZeros which violates this contract, it may cause undefined behavior.

#[derive(FromZeros)] only permits types which satisfy these requirements.

Provided Methods§

Source

fn zero(&mut self)

Overwrites self with zeros.

Sets every byte in self to 0. While this is similar to doing *self = Self::new_zeroed(), it differs in that zero does not semantically drop the current value and replace it with a new one — it simply modifies the bytes of the existing value.

§Examples
#[derive(FromZeros)]
#[repr(C)]
struct PacketHeader {
    src_port: [u8; 2],
    dst_port: [u8; 2],
    length: [u8; 2],
    checksum: [u8; 2],
}

let mut header = PacketHeader {
    src_port: 100u16.to_be_bytes(),
    dst_port: 200u16.to_be_bytes(),
    length: 300u16.to_be_bytes(),
    checksum: 400u16.to_be_bytes(),
};

header.zero();

assert_eq!(header.src_port, [0, 0]);
assert_eq!(header.dst_port, [0, 0]);
assert_eq!(header.length, [0, 0]);
assert_eq!(header.checksum, [0, 0]);
Source

fn new_zeroed() -> Self
where Self: Sized,

Creates an instance of Self from zeroed bytes.

§Examples
#[derive(FromZeros)]
#[repr(C)]
struct PacketHeader {
    src_port: [u8; 2],
    dst_port: [u8; 2],
    length: [u8; 2],
    checksum: [u8; 2],
}

let header: PacketHeader = FromZeros::new_zeroed();

assert_eq!(header.src_port, [0, 0]);
assert_eq!(header.dst_port, [0, 0]);
assert_eq!(header.length, [0, 0]);
assert_eq!(header.checksum, [0, 0]);
Source

fn new_box_zeroed() -> Result<Box<Self>, AllocError>
where Self: Sized,

Creates a Box<Self> from zeroed bytes.

This function is useful for allocating large values on the heap and zero-initializing them, without ever creating a temporary instance of Self on the stack. For example, <[u8; 1048576]>::new_box_zeroed() will allocate [u8; 1048576] directly on the heap; it does not require storing [u8; 1048576] in a temporary variable on the stack.

On systems that use a heap implementation that supports allocating from pre-zeroed memory, using new_box_zeroed (or related functions) may have performance benefits.

§Errors

Returns an error on allocation failure. Allocation failure is guaranteed never to cause a panic or an abort.

Source

fn new_box_zeroed_with_elems(count: usize) -> Result<Box<Self>, AllocError>
where Self: KnownLayout<PointerMetadata = usize>,

Creates a Box<[Self]> (a boxed slice) from zeroed bytes.

This function is useful for allocating large values of [Self] on the heap and zero-initializing them, without ever creating a temporary instance of [Self; _] on the stack. For example, u8::new_box_slice_zeroed(1048576) will allocate the slice directly on the heap; it does not require storing the slice on the stack.

On systems that use a heap implementation that supports allocating from pre-zeroed memory, using new_box_slice_zeroed may have performance benefits.

If Self is a zero-sized type, then this function will return a Box<[Self]> that has the correct len. Such a box cannot contain any actual information, but its len() property will report the correct value.

§Errors

Returns an error on allocation failure. Allocation failure is guaranteed never to cause a panic or an abort.

Source

fn new_vec_zeroed(len: usize) -> Result<Vec<Self>, AllocError>
where Self: Sized,

Creates a Vec<Self> from zeroed bytes.

This function is useful for allocating large values of Vecs and zero-initializing them, without ever creating a temporary instance of [Self; _] (or many temporary instances of Self) on the stack. For example, u8::new_vec_zeroed(1048576) will allocate directly on the heap; it does not require storing intermediate values on the stack.

On systems that use a heap implementation that supports allocating from pre-zeroed memory, using new_vec_zeroed may have performance benefits.

If Self is a zero-sized type, then this function will return a Vec<Self> that has the correct len. Such a Vec cannot contain any actual information, but its len() property will report the correct value.

§Errors

Returns an error on allocation failure. Allocation failure is guaranteed never to cause a panic or an abort.

Source

fn extend_vec_zeroed( v: &mut Vec<Self>, additional: usize, ) -> Result<(), AllocError>
where Self: Sized,

Extends a Vec<Self> by pushing additional new items onto the end of the vector. The new items are initialized with zeros.

Source

fn insert_vec_zeroed( v: &mut Vec<Self>, position: usize, additional: usize, ) -> Result<(), AllocError>
where Self: Sized,

Inserts additional new items into Vec<Self> at position. The new items are initialized with zeros.

§Panics

Panics if position > v.len().

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl FromZeros for ()

Source§

impl FromZeros for Atomic<bool>

Source§

impl FromZeros for Atomic<i8>

Source§

impl FromZeros for Atomic<i16>

Source§

impl FromZeros for Atomic<i32>

Source§

impl FromZeros for Atomic<i64>

Source§

impl FromZeros for Atomic<isize>

Source§

impl FromZeros for Atomic<u8>

Source§

impl FromZeros for Atomic<u16>

Source§

impl FromZeros for Atomic<u32>

Source§

impl FromZeros for Atomic<u64>

Source§

impl FromZeros for Atomic<usize>

§

impl FromZeros for BtiInfo
where u64: FromZeros,

§

impl FromZeros for HandleCountInfo
where u32: FromZeros,

§

impl FromZeros for InfoMapsTypeUnion
where zx_info_maps_mapping_t: FromZeros,

§

impl FromZeros for InfoMapsTypeUnionV1
where zx_info_maps_mapping_v1_t: FromZeros,

§

impl FromZeros for InfoMapsTypeUnionV2
where zx_info_maps_mapping_v2_t: FromZeros,

§

impl FromZeros for Koid
where u64: FromZeros,

§

impl FromZeros for MapInfo
where Name: FromZeros, usize: FromZeros, u32: FromZeros, InfoMapsTypeUnion: FromZeros,

§

impl FromZeros for MappingDetails
where VmarFlagsExtended: FromZeros, [PadByte; 4]: FromZeros, Koid: FromZeros, u64: FromZeros, usize: FromZeros,

§

impl FromZeros for MemStats
where u64: FromZeros,

§

impl FromZeros for MemStatsCompression

§

impl FromZeros for MemStatsExtended
where u64: FromZeros,

§

impl FromZeros for MemoryStall
where i64: FromZeros,

§

impl FromZeros for Name
where [u8; 32]: FromZeros,

Source§

impl FromZeros for Option<NonZero<i8>>

Source§

impl FromZeros for Option<NonZero<i16>>

Source§

impl FromZeros for Option<NonZero<i32>>

Source§

impl FromZeros for Option<NonZero<i64>>

Source§

impl FromZeros for Option<NonZero<i128>>

Source§

impl FromZeros for Option<NonZero<isize>>

Source§

impl FromZeros for Option<NonZero<u8>>

Source§

impl FromZeros for Option<NonZero<u16>>

Source§

impl FromZeros for Option<NonZero<u32>>

Source§

impl FromZeros for Option<NonZero<u64>>

Source§

impl FromZeros for Option<NonZero<u128>>

Source§

impl FromZeros for Option<NonZero<usize>>

§

impl FromZeros for PadByte
where u8: FromZeros,

§

impl FromZeros for PerCpuStats

§

impl FromZeros for ProcessHandleStats
where [u32; 64]: FromZeros,

§

impl FromZeros for ProcessInfo
where i64: FromZeros, Instant<MonotonicTimeline>: FromZeros, ProcessInfoFlags: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for ProcessInfoFlags
where u32: FromZeros,

§

impl FromZeros for ResourceInfo

§

impl FromZeros for Rights
where u32: FromZeros,

§

impl FromZeros for TaskRuntimeInfo
where i64: FromZeros,

§

impl FromZeros for TaskStatsInfo

§

impl FromZeros for VmarFlags
where u32: FromZeros,

§

impl FromZeros for VmarFlagsExtended
where u32: FromZeros,

§

impl FromZeros for VmarInfo

§

impl FromZeros for VmoInfo
where Koid: FromZeros, Name: FromZeros, u64: FromZeros, usize: FromZeros, VmoInfoFlags: FromZeros, [PadByte; 4]: FromZeros, Rights: FromZeros, u32: FromZeros,

§

impl FromZeros for VmoInfoFlags
where u32: FromZeros,

Source§

impl FromZeros for __m128

Source§

impl FromZeros for __m256

Source§

impl FromZeros for __m512

Source§

impl FromZeros for __m128d

Source§

impl FromZeros for __m128i

Source§

impl FromZeros for __m256d

Source§

impl FromZeros for __m256i

Source§

impl FromZeros for __m512bh

Source§

impl FromZeros for __m512d

Source§

impl FromZeros for __m512i

Source§

impl FromZeros for bool

Source§

impl FromZeros for char

Source§

impl FromZeros for f32

Source§

impl FromZeros for f64

Source§

impl FromZeros for i8

Source§

impl FromZeros for i16

Source§

impl FromZeros for i32

Source§

impl FromZeros for i64

Source§

impl FromZeros for i128

Source§

impl FromZeros for isize

§

impl FromZeros for priority_params
where i32: FromZeros, [PadByte; 20]: FromZeros,

Source§

impl FromZeros for str

Source§

impl FromZeros for u8

Source§

impl FromZeros for u16

Source§

impl FromZeros for u32

Source§

impl FromZeros for u64

Source§

impl FromZeros for u128

Source§

impl FromZeros for usize

§

impl FromZeros for zx_arm64_exc_data_t
where u32: FromZeros, [PadByte; 4]: FromZeros, u64: FromZeros, [PadByte; 8]: FromZeros,

§

impl FromZeros for zx_arm64_info_guest_stats_t

§

impl FromZeros for zx_clock_create_args_v1_t
where i64: FromZeros,

§

impl FromZeros for zx_clock_details_v1_t
where u64: FromZeros, i64: FromZeros, zx_clock_transformation_t: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_clock_rate_t
where u32: FromZeros,

§

impl FromZeros for zx_clock_transformation_t
where i64: FromZeros, zx_clock_rate_t: FromZeros,

§

impl FromZeros for zx_clock_update_args_v1_t
where i32: FromZeros, [PadByte; 4]: FromZeros, i64: FromZeros, u64: FromZeros,

§

impl FromZeros for zx_clock_update_args_v2_t
where i32: FromZeros, [PadByte; 4]: FromZeros, i64: FromZeros, u64: FromZeros,

§

impl FromZeros for zx_cpu_perf_limit_t

§

impl FromZeros for zx_cpu_performance_info_t
where u32: FromZeros, zx_cpu_performance_scale_t: FromZeros,

§

impl FromZeros for zx_cpu_performance_scale_t
where u32: FromZeros,

§

impl FromZeros for zx_cpu_set_t
where [u64; 8]: FromZeros,

§

impl FromZeros for zx_exception_context_t
where zx_exception_header_arch_t: FromZeros, u32: FromZeros,

§

impl FromZeros for zx_exception_header_arch_t
where zx_x86_64_exc_data_t: FromZeros, zx_arm64_exc_data_t: FromZeros, zx_riscv64_exc_data_t: FromZeros,

§

impl FromZeros for zx_exception_header_t
where u32: FromZeros,

§

impl FromZeros for zx_exception_info_t
where u64: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_exception_report_t
where zx_exception_header_t: FromZeros, zx_exception_context_t: FromZeros,

§

impl FromZeros for zx_exception_report_v1_t
where zx_exception_header_t: FromZeros, [u8; 24]: FromZeros,

§

impl FromZeros for zx_info_bti_t
where u64: FromZeros,

§

impl FromZeros for zx_info_cpu_stats_t

§

impl FromZeros for zx_info_handle_basic_t
where u64: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_info_handle_count_t
where u32: FromZeros,

§

impl FromZeros for zx_info_handle_extended_t

§

impl FromZeros for zx_info_interrupt_t
where u32: FromZeros,

§

impl FromZeros for zx_info_iob_t
where u64: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_info_job_t
where i64: FromZeros, u8: FromZeros, [PadByte; 5]: FromZeros,

§

impl FromZeros for zx_info_kmem_stats_compression_t

§

impl FromZeros for zx_info_kmem_stats_extended_t
where u64: FromZeros,

§

impl FromZeros for zx_info_kmem_stats_t
where u64: FromZeros,

§

impl FromZeros for zx_info_kmem_stats_v1_t
where u64: FromZeros,

§

impl FromZeros for zx_info_maps_mapping_t
where u32: FromZeros, [PadByte; 4]: FromZeros, u64: FromZeros, usize: FromZeros,

§

impl FromZeros for zx_info_maps_mapping_v1_t
where u32: FromZeros, [PadByte; 4]: FromZeros, u64: FromZeros, usize: FromZeros,

§

impl FromZeros for zx_info_maps_mapping_v2_t
where u32: FromZeros, [PadByte; 4]: FromZeros, u64: FromZeros, usize: FromZeros,

§

impl FromZeros for zx_info_maps_t
where [u8; 32]: FromZeros, usize: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros, InfoMapsTypeUnion: FromZeros,

§

impl FromZeros for zx_info_maps_v1_t
where [u8; 32]: FromZeros, usize: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros, InfoMapsTypeUnionV1: FromZeros,

§

impl FromZeros for zx_info_maps_v2_t
where [u8; 32]: FromZeros, usize: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros, InfoMapsTypeUnionV2: FromZeros,

§

impl FromZeros for zx_info_memory_stall_t
where i64: FromZeros,

§

impl FromZeros for zx_info_msi_t

§

impl FromZeros for zx_info_process_handle_stats_t
where [u32; 64]: FromZeros,

§

impl FromZeros for zx_info_process_t
where i64: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_info_resource_t

§

impl FromZeros for zx_info_socket_t
where u32: FromZeros, [PadByte; 4]: FromZeros, usize: FromZeros,

§

impl FromZeros for zx_info_stream_t

§

impl FromZeros for zx_info_task_runtime_t
where i64: FromZeros,

§

impl FromZeros for zx_info_task_runtime_v1_t
where i64: FromZeros,

§

impl FromZeros for zx_info_task_stats_t

§

impl FromZeros for zx_info_task_stats_v1_t

§

impl FromZeros for zx_info_thread_stats_t
where i64: FromZeros, u32: FromZeros, [PadByte; 4]: FromZeros,

§

impl FromZeros for zx_info_thread_t
where u32: FromZeros, zx_cpu_set_t: FromZeros,

§

impl FromZeros for zx_info_timer_t

§

impl FromZeros for zx_info_vcpu_t
where u32: FromZeros,

§

impl FromZeros for zx_info_vmar_t

§

impl FromZeros for zx_info_vmo_t

§

impl FromZeros for zx_info_vmo_v1_t

§

impl FromZeros for zx_info_vmo_v2_t

§

impl FromZeros for zx_info_vmo_v3_t

§

impl FromZeros for zx_iob_discipline_extension_t
where zx_iob_discipline_mediated_write_ring_buffer_t: FromZeros, [PadByte; 64]: FromZeros,

§

impl FromZeros for zx_iob_discipline_mediated_write_ring_buffer_t
where u64: FromZeros, [PadByte; 56]: FromZeros,

§

impl FromZeros for zx_iob_discipline_t
where u64: FromZeros, zx_iob_discipline_extension_t: FromZeros,

§

impl FromZeros for zx_iob_region_extension_t
where zx_iob_region_private_t: FromZeros, zx_iob_region_shared_t: FromZeros, [u8; 32]: FromZeros,

§

impl FromZeros for zx_iob_region_info_t
where zx_iob_region_t: FromZeros, u64: FromZeros,

§

impl FromZeros for zx_iob_region_private_t
where u32: FromZeros, [PadByte; 28]: FromZeros,

§

impl FromZeros for zx_iob_region_shared_t
where u32: FromZeros, [PadByte; 24]: FromZeros,

§

impl FromZeros for zx_iob_region_t
where u32: FromZeros, u64: FromZeros, zx_iob_discipline_t: FromZeros, zx_iob_region_extension_t: FromZeros,

§

impl FromZeros for zx_log_record_header_t

§

impl FromZeros for zx_log_record_t
where zx_log_record_header_t: FromZeros, [u8; 216]: FromZeros,

§

impl FromZeros for zx_packet_guest_vcpu_interrupt_t
where u64: FromZeros, u8: FromZeros, [PadByte; 15]: FromZeros,

§

impl FromZeros for zx_packet_guest_vcpu_startup_t

§

impl FromZeros for zx_packet_guest_vcpu_union_t
where zx_packet_guest_vcpu_interrupt_t: FromZeros, zx_packet_guest_vcpu_startup_t: FromZeros,

§

impl FromZeros for zx_pager_vmo_stats_t
where u32: FromZeros,

§

impl FromZeros for zx_policy_basic_v1
where u32: FromZeros,

§

impl FromZeros for zx_policy_basic_v2
where u32: FromZeros,

§

impl FromZeros for zx_policy_timer_slack

§

impl FromZeros for zx_profile_info_t
where u32: FromZeros, [PadByte; 4]: FromZeros, zx_profile_info_union: FromZeros, zx_cpu_set_t: FromZeros,

§

impl FromZeros for zx_profile_info_union
where priority_params: FromZeros, zx_sched_deadline_params_t: FromZeros,

§

impl FromZeros for zx_riscv64_exc_data_t
where u64: FromZeros, [PadByte; 8]: FromZeros,

§

impl FromZeros for zx_riscv64_info_guest_stats_t

§

impl FromZeros for zx_rseq_t

§

impl FromZeros for zx_sampler_config_t

§

impl FromZeros for zx_sched_deadline_params_t
where i64: FromZeros,

§

impl FromZeros for zx_smc_parameters_t
where u32: FromZeros, [PadByte; 4]: FromZeros, u64: FromZeros, u16: FromZeros,

§

impl FromZeros for zx_smc_result_t
where u64: FromZeros,

§

impl FromZeros for zx_thread_state_general_regs_t
where u64: FromZeros,

§

impl FromZeros for zx_vcpu_io_t
where u8: FromZeros, [PadByte; 3]: FromZeros, [u8; 4]: FromZeros,

§

impl FromZeros for zx_vcpu_state_t
where u64: FromZeros,

§

impl FromZeros for zx_vmo_dirty_range_t
where u64: FromZeros,

§

impl FromZeros for zx_vmo_lock_state_t
where u64: FromZeros,

§

impl FromZeros for zx_wait_item_t
where u32: FromZeros,

§

impl FromZeros for zx_wake_source_report_entry_t

§

impl FromZeros for zx_wake_source_report_header_t

§

impl FromZeros for zx_x86_64_exc_data_t
where u64: FromZeros,

§

impl FromZeros for zx_x86_64_info_guest_stats_t

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M, N)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L, M)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(A, B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<fn(A, B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(A, B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(A, B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L> FromZeros for (A, B, C, D, E, F, G, H, I, J, K, L)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K> FromZeros for (A, B, C, D, E, F, G, H, I, J, K)

Source§

impl<A, B, C, D, E, F, G, H, I, J> FromZeros for (A, B, C, D, E, F, G, H, I, J)

Source§

impl<A, B, C, D, E, F, G, H, I> FromZeros for (A, B, C, D, E, F, G, H, I)

Source§

impl<A, B, C, D, E, F, G, H> FromZeros for (A, B, C, D, E, F, G, H)

Source§

impl<A, B, C, D, E, F, G> FromZeros for (A, B, C, D, E, F, G)

Source§

impl<A, B, C, D, E, F> FromZeros for (A, B, C, D, E, F)

Source§

impl<A, B, C, D, E> FromZeros for (A, B, C, D, E)
where A: FromZeros, B: FromZeros, C: FromZeros, D: FromZeros, E: FromZeros,

Source§

impl<A, B, C, D> FromZeros for (A, B, C, D)
where A: FromZeros, B: FromZeros, C: FromZeros, D: FromZeros,

Source§

impl<A, B, C> FromZeros for (A, B, C)
where A: FromZeros, B: FromZeros, C: FromZeros,

Source§

impl<A, B> FromZeros for (A, B)
where A: FromZeros, B: FromZeros,

Source§

impl<A> FromZeros for (A,)
where A: FromZeros,

Source§

impl<B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<fn(B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<B, C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(B, C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<fn(C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<C, D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(C, D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<D, E, F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<D, E, F, G, H, I, J, K, L, M> FromZeros for Option<fn(D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<D, E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(D, E, F, G, H, I, J, K, L) -> M>

Source§

impl<E, F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(E, F, G, H, I, J, K, L) -> M>

Source§

impl<E, F, G, H, I, J, K, L, M> FromZeros for Option<fn(E, F, G, H, I, J, K, L) -> M>

Source§

impl<E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(E, F, G, H, I, J, K, L) -> M>

Source§

impl<E, F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(E, F, G, H, I, J, K, L) -> M>

Source§

impl<F, G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(F, G, H, I, J, K, L) -> M>

Source§

impl<F, G, H, I, J, K, L, M> FromZeros for Option<fn(F, G, H, I, J, K, L) -> M>

Source§

impl<F, G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(F, G, H, I, J, K, L) -> M>

Source§

impl<F, G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(F, G, H, I, J, K, L) -> M>

Source§

impl<G, H, I, J, K, L, M> FromZeros for Option<extern "C" fn(G, H, I, J, K, L) -> M>

Source§

impl<G, H, I, J, K, L, M> FromZeros for Option<fn(G, H, I, J, K, L) -> M>

Source§

impl<G, H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(G, H, I, J, K, L) -> M>

Source§

impl<G, H, I, J, K, L, M> FromZeros for Option<unsafe fn(G, H, I, J, K, L) -> M>

Source§

impl<H, I, J, K, L, M> FromZeros for Option<extern "C" fn(H, I, J, K, L) -> M>

Source§

impl<H, I, J, K, L, M> FromZeros for Option<fn(H, I, J, K, L) -> M>

Source§

impl<H, I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(H, I, J, K, L) -> M>

Source§

impl<H, I, J, K, L, M> FromZeros for Option<unsafe fn(H, I, J, K, L) -> M>

Source§

impl<I, J, K, L, M> FromZeros for Option<extern "C" fn(I, J, K, L) -> M>

Source§

impl<I, J, K, L, M> FromZeros for Option<fn(I, J, K, L) -> M>

Source§

impl<I, J, K, L, M> FromZeros for Option<unsafe extern "C" fn(I, J, K, L) -> M>

Source§

impl<I, J, K, L, M> FromZeros for Option<unsafe fn(I, J, K, L) -> M>

Source§

impl<J, K, L, M> FromZeros for Option<extern "C" fn(J, K, L) -> M>

Source§

impl<J, K, L, M> FromZeros for Option<fn(J, K, L) -> M>

Source§

impl<J, K, L, M> FromZeros for Option<unsafe extern "C" fn(J, K, L) -> M>

Source§

impl<J, K, L, M> FromZeros for Option<unsafe fn(J, K, L) -> M>

Source§

impl<K, L, M> FromZeros for Option<extern "C" fn(K, L) -> M>

Source§

impl<K, L, M> FromZeros for Option<fn(K, L) -> M>

Source§

impl<K, L, M> FromZeros for Option<unsafe extern "C" fn(K, L) -> M>

Source§

impl<K, L, M> FromZeros for Option<unsafe fn(K, L) -> M>

Source§

impl<L, M> FromZeros for Option<extern "C" fn(L) -> M>

Source§

impl<L, M> FromZeros for Option<fn(L) -> M>

Source§

impl<L, M> FromZeros for Option<unsafe extern "C" fn(L) -> M>

Source§

impl<L, M> FromZeros for Option<unsafe fn(L) -> M>

Source§

impl<M> FromZeros for Option<extern "C" fn() -> M>

Source§

impl<M> FromZeros for Option<fn() -> M>

Source§

impl<M> FromZeros for Option<unsafe extern "C" fn() -> M>

Source§

impl<M> FromZeros for Option<unsafe fn() -> M>

§

impl<T, U> FromZeros for Duration<T, U>

§

impl<T, U> FromZeros for Instant<T, U>

Source§

impl<T, const N: usize> FromZeros for [T; N]
where T: FromZeros,

Source§

impl<T> FromZeros for *const T

Source§

impl<T> FromZeros for *mut T

Source§

impl<T> FromZeros for Atomic<*mut T>

Source§

impl<T> FromZeros for Cell<T>
where T: FromZeros + ?Sized,

Source§

impl<T> FromZeros for ManuallyDrop<T>
where T: FromZeros + ?Sized,

Source§

impl<T> FromZeros for MaybeUninit<T>

Source§

impl<T> FromZeros for Option<&T>

Source§

impl<T> FromZeros for Option<&mut T>

Source§

impl<T> FromZeros for Option<Box<T>>

Source§

impl<T> FromZeros for Option<NonNull<T>>

Source§

impl<T> FromZeros for PhantomData<T>
where T: ?Sized,

§

impl<T> FromZeros for TimerInfo<T>
where T: Timeline, u32: FromZeros, Instant<T>: FromZeros, Duration<T>: FromZeros,

Source§

impl<T> FromZeros for UnsafeCell<T>
where T: FromZeros + ?Sized,

Source§

impl<T> FromZeros for Wrapping<T>
where T: FromZeros,

Source§

impl<T> FromZeros for [T]
where T: FromZeros,

Implementors§

Source§

impl<O> FromZeros for F32<O>

Source§

impl<O> FromZeros for F64<O>

Source§

impl<O> FromZeros for I16<O>

Source§

impl<O> FromZeros for I32<O>

Source§

impl<O> FromZeros for I64<O>

Source§

impl<O> FromZeros for I128<O>

Source§

impl<O> FromZeros for Isize<O>

Source§

impl<O> FromZeros for U16<O>

Source§

impl<O> FromZeros for U32<O>

Source§

impl<O> FromZeros for U64<O>

Source§

impl<O> FromZeros for U128<O>

Source§

impl<O> FromZeros for Usize<O>

Source§

impl<T> FromZeros for ReadOnly<T>
where T: FromZeros + ?Sized,

Source§

impl<T> FromZeros for Unalign<T>
where T: FromZeros,