Select

Trait Select 

Source
pub trait Select {
    // Required method
    fn select(&mut self, other: &Self, selector: U8);
}
Expand description

Best effort constant time selection of values.

Required Methods§

Source

fn select(&mut self, other: &Self, selector: U8)

Select self or other, depending on selector. The selected value will be in self.

If selector != 0, select other, otherwise self is unchanged.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Select for [u8]

Source§

fn select(&mut self, other: &Self, selector: U8)

Source§

impl Select for [u16]

Source§

fn select(&mut self, other: &Self, selector: U8)

Source§

impl Select for [u32]

Source§

fn select(&mut self, other: &Self, selector: U8)

Source§

impl Select for [u64]

Source§

fn select(&mut self, other: &Self, selector: U8)

Implementors§