[][src]Enum cranelift_codegen::settings::detail::Detail

pub enum Detail {
    Bool {
        bit: u8,
    },
    Num,
    Enum {
        last: u8,
        enumerators: u16,
    },
    Preset,
}

The different kind of settings along with descriptor bits that depend on the kind.

Variants

Bool

A boolean setting only uses one bit, numbered from LSB.

Fields of Bool

bit: u8

0-7.

Num

A numerical setting uses the whole byte.

Enum

An Enum setting uses a range of enumerators.

Fields of Enum

last: u8

Numerical value of last enumerator, allowing for 1-256 enumerators.

enumerators: u16

First enumerator in the ENUMERATORS table.

Preset

A preset is not an individual setting, it is a collection of settings applied at once.

The Descriptor::offset field refers to the PRESETS table.

Methods

impl Detail[src]

pub fn is_preset(self) -> bool[src]

Check if a detail is a Detail::Preset. Useful because the Descriptor offset field has a different meaning when the detail is a preset.

Trait Implementations

impl Copy for Detail[src]

impl Clone for Detail[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Unpin for Detail

impl Send for Detail

impl Sync for Detail

impl RefUnwindSafe for Detail

impl UnwindSafe for Detail

Blanket Implementations

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.