wiwi::num

Trait FromBoolLossy

Source
pub trait FromBoolLossy
where Self: Sealed,
{ // Required method fn from_bool_lossy(value: bool) -> Self; }
Expand description

Trait for number types that can be converted from bool, potentially lossily

Required Methods§

Source

fn from_bool_lossy(value: bool) -> Self

Convert from a bool value

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 FromBoolLossy for f32

Source§

impl FromBoolLossy for f64

Source§

impl FromBoolLossy for i8

Source§

impl FromBoolLossy for i16

Source§

impl FromBoolLossy for i32

Source§

impl FromBoolLossy for i64

Source§

impl FromBoolLossy for i128

Source§

impl FromBoolLossy for isize

Source§

impl FromBoolLossy for u8

Source§

impl FromBoolLossy for u16

Source§

impl FromBoolLossy for u32

Source§

impl FromBoolLossy for u64

Source§

impl FromBoolLossy for u128

Source§

impl FromBoolLossy for usize

Implementors§