Skip to main content

FillDefault

Trait FillDefault 

Source
pub trait FillDefault {
    // Required method
    fn fill_default(&mut self);
}
Expand description

Output row storage that can fill itself with default placeholder values.

OutputSink::Rows requires this so the default OutputSink::initialize_skipped_rows can make skipped rows safe to finish. The written values are placeholders only: valid rows are overwritten by the kernel, and batch execution masks skipped rows before the output is observable.

The blanket slice implementation writes T::default() into every element. Coherence with that blanket prevents an implementation for raw MaybeUninit slices, so a sink exposing uninitialized storage implements this on its own row view type, like UninitElementSink.

Required Methods§

Source

fn fill_default(&mut self)

Fill every element with its default value.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl FillDefault for ()

Source§

fn fill_default(&mut self)

Source§

impl<T: Default + Clone> FillDefault for Vec<T>

Source§

fn fill_default(&mut self)

Source§

impl<T: Default + Clone> FillDefault for [T]

Source§

fn fill_default(&mut self)

Source§

impl<T: FillDefault + ?Sized> FillDefault for &mut T

Source§

fn fill_default(&mut self)

Implementors§