Fixed
A signed 64.64 fixed-point number.
Uses 64 bits for the integer part and 64 bits for the fractional part, providing approximately 19 decimal digits of precision.
Fields
mag- The absolute magnitude, scaled by 2^64sign- The sign:truefor negative,falsefor positive/zero
Example
// Create 2.5: magnitude = 2.5 * 2^64
let value = Fixed { mag: 46116860184273879040, sign: false };
Fully qualified path: cairo_fp::f128::types::fixed::Fixed
[derive(Copy, Drop, Serde)]
struct Fixed {
mag: u128,
sign: bool,
}
Members
mag
Fully qualified path: cairo_fp::f128::types::fixed::Fixed::mag
mag: u128
sign
Fully qualified path: cairo_fp::f128::types::fixed::Fixed::sign
sign: bool