Numeric Types
Like all type expressions, this expression produces a value of the type type.
Numeric-typed values are either integer or floating-point numbers, with a specific representation, precision, and range of representable values dependent on the type itself.
Representation
i8,i16,i32, andi64are signed binary integers in two's complement representation, exactly 8, 16, 32, and 64 bits in size respectively.u8,u16,u32, andu64are unsigned binary integers, exactly 8, 16, 32, and 64 bits in size respectively.f32andf64are IEEE 754 single-precision and double-precision binary floating-point numbers respectively.
Syntax
numeric_type = i8 | i16 | i32 | i64
| u8 | u16 | u32 | u64
| f32 | f64 ;