Expand description
Fixed-point decimal with nine fractional digits.
A Decimal is an i128 count of units of 10^-9. It is exact: parsing
never rounds, and every arithmetic operation either returns an exact or
explicitly rounded result or a typed ArithError. Nothing saturates,
wraps or clamps.
Structs§
- Decimal
- An exact decimal value
units / 10^9.
Enums§
- Arith
Error - Why an arithmetic operation produced no value.
- Decimal
Error - Why a decimal string was refused.
- Rounding
- Rounding applied when a result has more than
SCALEfractional digits, or whenDecimal::round_to_scaledrops digits.