document type properties
This commit is contained in:
parent
40ba11f33c
commit
3b126e7fa6
12
src/lib.rs
12
src/lib.rs
|
|
@ -31,7 +31,17 @@ const E_BIAS: u8 = E_STORAGE_MAX - E_MAX;
|
||||||
const M_MASK: u8 = M_STORAGE_MAX;
|
const M_MASK: u8 = M_STORAGE_MAX;
|
||||||
const E_MASK: u8 = E_STORAGE_MAX << M_BITS;
|
const E_MASK: u8 = E_STORAGE_MAX << M_BITS;
|
||||||
|
|
||||||
/// 8-bit unsigned binary floating-point type, with [`M_BITS`] mantissa bits and [`E_BITS`] exponent bits.
|
/// 8-bit unsigned binary floating-point type.
|
||||||
|
///
|
||||||
|
/// # Properties
|
||||||
|
///
|
||||||
|
/// * Mantissa width: 5 bits ([`M_BITS`])
|
||||||
|
/// * Exponent width: 3 bits ([`E_BITS`])
|
||||||
|
/// * Negative values: not supported
|
||||||
|
/// * Zero: special-cased
|
||||||
|
/// * Subnormals: not supported
|
||||||
|
/// * Infinity: not supported
|
||||||
|
/// * NaN: not supported
|
||||||
#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Default)]
|
#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Default)]
|
||||||
#[repr(transparent)]
|
#[repr(transparent)]
|
||||||
pub struct F8(u8);
|
pub struct F8(u8);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user