Appearance
cellpack::loader::Conversion
Module contract · All interfaces
At a glance
#[repr(u8)]pub enum Conversion {
Same = 0,
Widen = 1,
Reinterpret = 2,
IntToF32 = 3,
IntToF64 = 4,
F32ToF64 = 5,
}Cost classes of conversions, as the cost model prices them.
Fields and variants
Same
Same = 0No conversion: the same element type.
Widen
Widen = 1Integer widening (zero or sign extension).
Reinterpret
Reinterpret = 2Same-width signed to unsigned.
IntToF32
IntToF32 = 3Any integer to f32 (exact up to 2^24).
IntToF64
IntToF64 = 4Any integer to f64.
F32ToF64
F32ToF64 = 5f32 to f64.
Member index
1 of 1 members
ofThe class of the pair s -> t , for every pair allowed accepts. Same-width signed-to-unsigned pairs are reinterpretations, wider pairs widenings.
Methods and associated constants
of
The class of the pair s -> t, for every pair allowed accepts. Same-width signed-to-unsigned pairs are reinterpretations, wider pairs widenings.
Implemented traits
impl Clone for Conversionimpl Debug for Conversionimpl PartialEq for ConversionContract reference
See the module reference for semantic input/output rules, units, allocation, mutation, failure behavior, and lifetime requirements. Declarations and documented members are synchronized from the crate source.