pub enum PrimitiveType {
    Boolean,
    Int {
        bits: u8,
    },
    UInt {
        bits: u8,
        mode: CastMode,
    },
    Float16 {
        mode: CastMode,
    },
    Float32 {
        mode: CastMode,
    },
    Float64 {
        mode: CastMode,
    },
}
Expand description

A primitive type

Variants

Boolean

Boolean, always saturated

Int

Fields

bits: u8

Signed integer, always saturated

UInt

Fields

bits: u8
mode: CastMode

Unsigned integer

Float16

Fields

mode: CastMode

16-bit float

Float32

Fields

mode: CastMode

32-bit float

Float64

Fields

mode: CastMode

64-bit float

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.