Expand description
Const-generic base-10 fixed-point decimal types for deterministic arithmetic.
§Overview
decimal-scaled provides a family of fixed-point decimal types whose stored
integer encodes actual_value * 10^SCALE. Decimal literals like 1.1
round-trip exactly without any binary approximation, and all core arithmetic
is integer-only — identical bit-patterns on every platform.
§Primary types
Each width has a D<digits><const SCALE: u32> const-generic shape with the
same method surface; pick the narrowest that fits your range. The number on
every D{N} type is MAX_SCALE — the highest SCALE the storage can hold.
| Type | Storage | MAX_SCALE | Feature gate |
|---|---|---|---|
D9<SCALE> | i32 | 9 | always on |
D18<SCALE> | i64 | 18 | always on |
D38<SCALE> | i128 | 38 | always on |
D57<SCALE> | 192-bit | 57 | d57 or wide |
D76<SCALE> | 256-bit | 76 | d76 or wide |
D115<SCALE> | 384-bit | 115 | d115 or wide |
D153<SCALE> | 512-bit | 153 | d153 or wide |
D230<SCALE> | 768-bit | 230 | d230 or wide |
D307<SCALE> | 1024-bit | 307 | d307 or wide |
D462<SCALE> | 1536-bit | 462 | d462 or x-wide |
D616<SCALE> | 2048-bit | 616 | d616 or x-wide |
D924<SCALE> | 3072-bit | 924 | d924 or xx-wide |
D1232<SCALE> | 4096-bit | 1232 | d1232 or xx-wide |
Umbrellas: wide enables D57 / D76 / D115 / D153 / D230 / D307;
x-wide adds D462 + D616; xx-wide adds D924 + D1232. Every
adjacent pair has lossless .widen() / fallible .narrow()
helpers plus From / TryFrom impls.
Concrete scale aliases such as D38s12 = D38<12> are emitted for every
supported SCALE. SCALE = MAX_SCALE + 1 is rejected at compile time —
10^(MAX_SCALE+1) overflows the storage type.
The width-generic Decimal trait carries the surface that is identical
across widths (constants, arithmetic operators, sign methods, integer
variants, pow / checked / wrapping / saturating / overflowing, float bridge,
Euclidean / floor / ceil division, etc.). Use it to write helpers that work
across widths; reach for the concrete type for width-specific operations
like rescale::<TARGET>() whose const-generic parameter cannot live on a
trait method.
§Equality and hashing
Because each logical value has exactly one representation at a fixed scale,
Hash, Eq, PartialEq, PartialOrd, and Ord are all derived from the
underlying integer storage. Two Dxx<S> values compare equal if and only
if their raw bit patterns are identical. This gives predictable behaviour
when decimal values are used as HashMap keys, unlike variable-scale
decimal types where 1.10 and 1.1 may hash differently.
§num-traits compatibility
Every width implements the standard num-traits 0.2 surface:
Zero, One, Num, Bounded, Signed, FromPrimitive,
ToPrimitive, and the Checked{Add,Sub,Mul,Div,Rem,Neg} family
(see ::num_traits). These impls are unconditional (not behind a
feature flag) because generic numeric code in the wider ecosystem
consumes this surface by default.
§no_std support
The crate compiles with no_std + alloc when default features are
disabled. alloc is required for Display::to_string and
FromStr::from_str. Targets without alloc are not supported.
§Feature flags
std(default): enables the fast implementations of transcendental functions (trigonometry, logarithms, exponentials, square root, cube root, float power) that delegate to platformf64intrinsics.alloc: pulled in automatically; required for string formatting and parsing.serde: enablesserde_helpersfor serialisation and deserialisation.strict: enables integer-only implementations of all transcendental functions. Whenstrictis active each function that would otherwise route throughf64is instead implemented using integer-only algorithms. Explicit float-conversion methods (to_f64,from_f64, etc.) remain available regardless; they are type conversions, not mathematical operations.strictdoes not requirestd; the integer transcendental implementations compile underno_std + alloc.
Modules§
- serde_
helpers serdeintegration for every decimal width.
Macros§
- d9
- The narrow-tier proc-macros are always available with the
macrosfeature; the wide-tier proc-macros are additionally feature-gated to match their target type’s availability.d9!— construct adecimal_scaled::D9<SCALE>value at compile time. See the crate-level docs andmacros/README.md. - d9s0
d9s0!(value)— equivalent tod9!(value, scale 0).- d9s2
d9s2!(value)— equivalent tod9!(value, scale 2).- d9s4
d9s4!(value)— equivalent tod9!(value, scale 4).- d9s6
d9s6!(value)— equivalent tod9!(value, scale 6).- d18
- The narrow-tier proc-macros are always available with the
macrosfeature; the wide-tier proc-macros are additionally feature-gated to match their target type’s availability.d18!— construct adecimal_scaled::D18<SCALE>value at compile time. See the crate-level docs andmacros/README.md. - d38
- The narrow-tier proc-macros are always available with the
macrosfeature; the wide-tier proc-macros are additionally feature-gated to match their target type’s availability.d38!— construct adecimal_scaled::D38<SCALE>value at compile time. See the crate-level docs andmacros/README.md. - d57
d57!— construct adecimal_scaled::D57<SCALE>value at compile time. Requires the parent crate’sd57/widefeature.- d76
d76!— construct adecimal_scaled::D76<SCALE>value at compile time. Requires the parent crate’sd76/widefeature.- d18s0
d18s0!(value)— equivalent tod18!(value, scale 0).- d18s2
d18s2!(value)— equivalent tod18!(value, scale 2).- d18s4
d18s4!(value)— equivalent tod18!(value, scale 4).- d18s6
d18s6!(value)— equivalent tod18!(value, scale 6).- d18s9
d18s9!(value)— equivalent tod18!(value, scale 9).- d18s12
d18s12!(value)— equivalent tod18!(value, scale 12).- d38s0
d38s0!(value)— equivalent tod38!(value, scale 0).- d38s2
d38s2!(value)— equivalent tod38!(value, scale 2).- d38s4
d38s4!(value)— equivalent tod38!(value, scale 4).- d38s6
d38s6!(value)— equivalent tod38!(value, scale 6).- d38s8
d38s8!(value)— equivalent tod38!(value, scale 8).- d38s9
d38s9!(value)— equivalent tod38!(value, scale 9).- d38s12
d38s12!(value)— equivalent tod38!(value, scale 12).- d38s15
d38s15!(value)— equivalent tod38!(value, scale 15).- d38s18
d38s18!(value)— equivalent tod38!(value, scale 18).- d38s24
d38s24!(value)— equivalent tod38!(value, scale 24).- d38s35
d38s35!(value)— equivalent tod38!(value, scale 35).- d76s0
d76s0!(value)— equivalent tod76!(value, scale 0).- d76s2
d76s2!(value)— equivalent tod76!(value, scale 2).- d76s6
d76s6!(value)— equivalent tod76!(value, scale 6).- d76s12
d76s12!(value)— equivalent tod76!(value, scale 12).- d76s18
d76s18!(value)— equivalent tod76!(value, scale 18).- d76s35
d76s35!(value)— equivalent tod76!(value, scale 35).- d76s50
d76s50!(value)— equivalent tod76!(value, scale 50).- d115
d115!— construct adecimal_scaled::D115<SCALE>value at compile time. Requires the parent crate’sd115/widefeature.- d153
d153!— construct adecimal_scaled::D153<SCALE>value at compile time. Requires the parent crate’sd153/widefeature.- d230
d230!— construct adecimal_scaled::D230<SCALE>value at compile time. Requires the parent crate’sd230/widefeature.- d307
d307!— construct adecimal_scaled::D307<SCALE>value at compile time. Requires the parent crate’sd307/x-widefeature.- d462
d462!— construct adecimal_scaled::D462<SCALE>value at compile time. Requires the parent crate’sd462/x-widefeature.- d616
d616!— construct adecimal_scaled::D616<SCALE>value at compile time. Requires the parent crate’sd616/x-widefeature.- d924
d924!— construct adecimal_scaled::D924<SCALE>value at compile time. Requires the parent crate’sd924/xx-widefeature.- d153s0
d153s0!(value)— equivalent tod153!(value, scale 0).- d153s35
d153s35!(value)— equivalent tod153!(value, scale 35).- d153s75
d153s75!(value)— equivalent tod153!(value, scale 75).- d153s150
d153s150!(value)— equivalent tod153!(value, scale 150).- d307s0
d307s0!(value)— equivalent tod307!(value, scale 0).- d307s35
d307s35!(value)— equivalent tod307!(value, scale 35).- d307s150
d307s150!(value)— equivalent tod307!(value, scale 150).- d307s300
d307s300!(value)— equivalent tod307!(value, scale 300).- d1232
d1232!— construct adecimal_scaled::D1232<SCALE>value at compile time. Requires the parent crate’sd1232/xx-widefeature.
Structs§
- D
- Generic scaled fixed-point decimal: storage integer
S, base-10 scaleSCALE. The logical value isself.0 / 10^SCALE. - Int192
- Hand-rolled fixed-width two’s-complement signed integer.
- Int256
- Hand-rolled fixed-width two’s-complement signed integer.
- Int384
- Hand-rolled fixed-width two’s-complement signed integer.
- Int512
- Hand-rolled fixed-width two’s-complement signed integer.
- Int768
- Hand-rolled fixed-width two’s-complement signed integer.
- Int1024
- Hand-rolled fixed-width two’s-complement signed integer.
- Int1536
- Hand-rolled fixed-width two’s-complement signed integer.
- Int2048
- Hand-rolled fixed-width two’s-complement signed integer.
- Int3072
- Hand-rolled fixed-width two’s-complement signed integer.
- Int4096
- Hand-rolled fixed-width two’s-complement signed integer.
- Int6144
- Hand-rolled fixed-width two’s-complement signed integer.
- Int8192
- Hand-rolled fixed-width two’s-complement signed integer.
- Int12288
- Hand-rolled fixed-width two’s-complement signed integer.
- Int16384
- Hand-rolled fixed-width two’s-complement signed integer.
- Uint192
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint256
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint384
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint512
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint768
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint1024
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint1536
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint2048
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint3072
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint4096
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint6144
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint8192
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint12288
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them). - Uint16384
- Hand-rolled fixed-width unsigned integer, little-endian u64
limbs (
$Lof them).
Enums§
- Convert
Error - Error returned by the fallible
TryFromimpls. - Decimal
Width - Discriminator for the concrete decimal width carried by a
DynDecimalvalue. - Parse
Error - Error returned by
FromStrwhen the input is not a valid canonical decimal literal. - RawStorage
- Tagged-union view of the raw storage integer behind a
DynDecimalvalue, with the scale stripped. - Rounding
Mode - Selector for the rounding rule applied when a scale-narrowing operation discards fractional digits.
Traits§
- Decimal
- Marker supertrait combining the four halves of the decimal API
surface (
DecimalArithmetic,DecimalConvert,crate::DecimalTranscendental,crate::DecimalConstants). - Decimal
Arithmetic - Arithmetic surface shared by every decimal width: type info,
constants, operators, sign methods, integer-shape predicates,
integer-style division helpers, integer-exponent powers, the
checked / wrapping / saturating / overflowing variants of every
operator, and reductions (
sum/product). - Decimal
Constants - Well-known mathematical constants available on every decimal width
(
D9/D18/D38/D76/D153/D307). - Decimal
Convert - Round-trip + conversion surface shared by every decimal width.
- Decimal
Transcendental - Width-generic transcendental + root surface shared by every decimal width. See the module-level docs for the four-variant matrix convention and the per-method delegation contract.
- DynDecimal
- Object-safe, width-erased view of a decimal value.
Type Aliases§
- D9
- Scaled fixed-point decimal with 32-bit storage. See
D38for the shape documentation; D9 has the same surface scaled toi32andMAX_SCALE = 9. - D9s0
- Scale alias:
D9<0>. 1 LSB = 1 (thini32wrapper). Range ±2.1 × 10⁹. - D9s1
- Scale alias:
D9<1>. 1 LSB = 10^-1. Range ±2.1 × 10⁸. - D9s2
- Scale alias:
D9<2>. 1 LSB = 10^-2 (cents). Range ±2.1 × 10⁷. - D9s3
- Scale alias:
D9<3>. 1 LSB = 10^-3 (mills). Range ±2.1 × 10⁶. - D9s4
- Scale alias:
D9<4>. 1 LSB = 10^-4 (basis points). Range ±2.1 × 10⁵. - D9s5
- Scale alias:
D9<5>. 1 LSB = 10^-5. Range ±2.1 × 10⁴. - D9s6
- Scale alias:
D9<6>. 1 LSB = 10^-6 (ppm). Range ±2.1 × 10³. - D9s7
- Scale alias:
D9<7>. 1 LSB = 10^-7. Range ±214. - D9s8
- Scale alias:
D9<8>. 1 LSB = 10^-8 (satoshi). Range ±21.4. - D18
- Scaled fixed-point decimal with 64-bit storage. See
D38for the shape documentation; D18 has the same surface scaled toi64andMAX_SCALE = 18. - D38
- Scaled fixed-point decimal with 128-bit storage. Now a type alias
of the unified
crate::Dgeneric decimal type:D38<S>isD<i128, S>. Both spellings are interchangeable. - D57
- Scaled fixed-point decimal with 192-bit storage. Half-width tier
between D38 and D76 — useful when the D38 i128 ceiling is in
reach but D76’s 256-bit storage is wasteful. Now a type alias of
the unified
crate::Dgeneric decimal type:D57<S>isD<crate::wide_int::Int192, S>. Both spellings are interchangeable. - D76
- Scaled fixed-point decimal with 256-bit storage. See
D38for the shape documentation; D76 has the same surface scaled to a 256-bit signed integer andMAX_SCALE = 76. Now a type alias of the unifiedcrate::Dgeneric decimal type:D76<S>isD<crate::wide_int::Int256, S>. Both spellings are interchangeable. - D18s0
- Scale alias:
D18<0>. 1 LSB = 1. Range ±9.2 × 10¹⁸. - D18s1
- Scale alias:
D18<1>. 1 LSB = 10^-1. Range ±9.2 × 10¹⁷. - D18s2
- Scale alias:
D18<2>. 1 LSB = 10^-2 (cents). Range ±9.2 × 10¹⁶. - D18s3
- Scale alias:
D18<3>. 1 LSB = 10^-3 (mills). Range ±9.2 × 10¹⁵. - D18s4
- Scale alias:
D18<4>. 1 LSB = 10^-4 (basis points). Range ±9.2 × 10¹⁴. - D18s5
- Scale alias:
D18<5>. 1 LSB = 10^-5. Range ±9.2 × 10¹³. - D18s6
- Scale alias:
D18<6>. 1 LSB = 10^-6 (ppm). Range ±9.2 × 10¹². - D18s7
- Scale alias:
D18<7>. 1 LSB = 10^-7. Range ±9.2 × 10¹¹. - D18s8
- Scale alias:
D18<8>. 1 LSB = 10^-8 (satoshi). Range ±9.2 × 10¹⁰. - D18s9
- Scale alias:
D18<9>. 1 LSB = 10^-9 (nano). Range ±9.2 × 10⁹. - D18s10
- Scale alias:
D18<10>. 1 LSB = 10^-10. Range ±9.2 × 10⁸. - D18s11
- Scale alias:
D18<11>. 1 LSB = 10^-11. Range ±9.2 × 10⁷. - D18s12
- Scale alias:
D18<12>. 1 LSB = 10^-12 (pico). Range ±9.2 × 10⁶. - D18s13
- Scale alias:
D18<13>. 1 LSB = 10^-13. Range ±9.2 × 10⁵. - D18s14
- Scale alias:
D18<14>. 1 LSB = 10^-14. Range ±9.2 × 10⁴. - D18s15
- Scale alias:
D18<15>. 1 LSB = 10^-15 (femto). Range ±9200. - D18s16
- Scale alias:
D18<16>. 1 LSB = 10^-16. Range ±920. - D18s17
- Scale alias:
D18<17>. 1 LSB = 10^-17. Range ±92. - D38s0
- Scale alias:
D38<0>. 1 LSB = 1 (thini128wrapper, no rescale). Range ~+/-1.7e38. - D38s1
- Scale alias:
D38<1>. 1 LSB = 10^-1 (1 decimal digit). Range ~+/-1.7e37. - D38s2
- Scale alias:
D38<2>. 1 LSB = 10^-2 (cents). Range ~+/-1.7e36. - D38s3
- Scale alias:
D38<3>. 1 LSB = 10^-3 (thousandths; 1 mm at m units). Range ~+/-1.7e35. - D38s4
- Scale alias:
D38<4>. 1 LSB = 10^-4 (basis points). Range ~+/-1.7e34. - D38s5
- Scale alias:
D38<5>. 1 LSB = 10^-5. Range ~+/-1.7e33. - D38s6
- Scale alias:
D38<6>. 1 LSB = 10^-6 (1 um at mm units; ppm). Range ~+/-1.7e32. - D38s7
- Scale alias:
D38<7>. 1 LSB = 10^-7. Range ~+/-1.7e31. - D38s8
- Scale alias:
D38<8>. 1 LSB = 10^-8 (satoshi-grade). Range ~+/-1.7e30. - D38s9
- Scale alias:
D38<9>. 1 LSB = 10^-9 (1 nm at mm units; ppb). Range ~+/-1.7e29. - D38s10
- Scale alias:
D38<10>. 1 LSB = 10^-10. Range ~+/-1.7e28. - D38s11
- Scale alias:
D38<11>. 1 LSB = 10^-11. Range ~+/-1.7e27. - D38s12
- Scale alias:
D38<12>. 1 LSB = 10^-12 (1 pm at mm units). Range ~+/-1.7e14 model units. - D38s13
- Scale alias:
D38<13>. 1 LSB = 10^-13. Range ~+/-1.7e25. - D38s14
- Scale alias:
D38<14>. 1 LSB = 10^-14. Range ~+/-1.7e24. - D38s15
- Scale alias:
D38<15>. 1 LSB = 10^-15 (femto). Range ~+/-1.7e23. - D38s16
- Scale alias:
D38<16>. 1 LSB = 10^-16. Range ~+/-1.7e22. - D38s17
- Scale alias:
D38<17>. 1 LSB = 10^-17. Range ~+/-1.7e21. - D38s18
- Scale alias:
D38<18>. 1 LSB = 10^-18 (atto; high-precision scientific). Range ~+/-1.7e20. - D38s19
- Scale alias:
D38<19>. 1 LSB = 10^-19. Range ~+/-1.7e19. - D38s20
- Scale alias:
D38<20>. 1 LSB = 10^-20. Range ~+/-1.7e18. - D38s21
- Scale alias:
D38<21>. 1 LSB = 10^-21 (zepto). Range ~+/-1.7e17. - D38s22
- Scale alias:
D38<22>. 1 LSB = 10^-22. Range ~+/-1.7e16. - D38s23
- Scale alias:
D38<23>. 1 LSB = 10^-23. Range ~+/-1.7e15. - D38s24
- Scale alias:
D38<24>. 1 LSB = 10^-24 (yocto). Range ~+/-1.7e14. - D38s25
- Scale alias:
D38<25>. 1 LSB = 10^-25. Range ~+/-1.7e13. - D38s26
- Scale alias:
D38<26>. 1 LSB = 10^-26. Range ~+/-1.7e12. - D38s27
- Scale alias:
D38<27>. 1 LSB = 10^-27. Range ~+/-1.7e11. - D38s28
- Scale alias:
D38<28>. 1 LSB = 10^-28. Range ~+/-1.7e10. - D38s29
- Scale alias:
D38<29>. 1 LSB = 10^-29. Range ~+/-1.7e9. - D38s30
- Scale alias:
D38<30>. 1 LSB = 10^-30. Range ~+/-1.7e8. - D38s31
- Scale alias:
D38<31>. 1 LSB = 10^-31. Range ~+/-1.7e7. - D38s32
- Scale alias:
D38<32>. 1 LSB = 10^-32. Range ~+/-1.7e6. - D38s33
- Scale alias:
D38<33>. 1 LSB = 10^-33. Range ~+/-1.7e5. - D38s34
- Scale alias:
D38<34>. 1 LSB = 10^-34. Range ~+/-1.7e4. - D38s35
- Scale alias:
D38<35>. 1 LSB = 10^-35. Range ~+/-1.7e3. - D38s36
- Scale alias:
D38<36>. 1 LSB = 10^-36. Range ~+/-170. - D38s37
- Scale alias:
D38<37>. 1 LSB = 10^-37. Range ~+/-17. - D57s0
- D57s1
- D57s2
- D57s4
- D57s6
- D57s9
- D57s12
- D57s18
- D57s20
- D57s24
- D57s28
- D57s32
- D57s38
- D57s42
- D57s48
- D57s52
- D57s56
- Scale alias:
D57<56>. 1 LSB = 10^-56. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D76s0
- Scale alias:
D76<0>. 1 LSB = 1 (256-bit integer ledger). - D76s1
- Scale alias:
D76<1>. 1 LSB = 10^-1 (tenths). - D76s2
- Scale alias:
D76<2>. 1 LSB = 10^-2 (cents). - D76s3
- D76s4
- D76s6
- Scale alias:
D76<6>. 1 LSB = 10^-6 (ppm). - D76s9
- D76s12
- Scale alias:
D76<12>. 1 LSB = 10^-12 (pico; financial standard). - D76s15
- D76s18
- Scale alias:
D76<18>. 1 LSB = 10^-18 (atto). - D76s20
- D76s24
- D76s28
- D76s32
- D76s35
- Scale alias:
D76<35>. 1 LSB = 10^-35 (matchesSCALE_REF). - D76s38
- D76s42
- D76s48
- D76s50
- Scale alias:
D76<50>. 1 LSB = 10^-50 (deep scientific precision). - D76s56
- D76s64
- D76s70
- D76s75
- Scale alias:
D76<75>. 1 LSB = 10^-75. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D115
- Scaled fixed-point decimal with 384-bit storage. Half-width tier
between D76 and D153. Now a type alias of the unified
crate::Dgeneric decimal type:D115<S>isD<crate::wide_int::Int384, S>. Both spellings are interchangeable. - D153
- Scaled fixed-point decimal with 512-bit storage. See
D38for the shape documentation; D153 has the same surface scaled to a 512-bit signed integer andMAX_SCALE = 153. Now a type alias of the unifiedcrate::Dgeneric decimal type:D153<S>isD<crate::wide_int::Int512, S>. Both spellings are interchangeable. - D230
- Scaled fixed-point decimal with 768-bit storage. Half-width tier
between D153 and D307. Now a type alias of the unified
crate::Dgeneric decimal type:D230<S>isD<crate::wide_int::Int768, S>. Both spellings are interchangeable. - D307
- Scaled fixed-point decimal with 1024-bit storage. See
D38for the shape documentation; D307 has the same surface scaled to a 1024-bit signed integer andMAX_SCALE = 307. Now a type alias of the unifiedcrate::Dgeneric decimal type:D307<S>isD<crate::wide_int::Int1024, S>. Both spellings are interchangeable. - D462
- Scaled fixed-point decimal with 1536-bit storage. Half-width tier
between D307 and D616. Now a type alias of the unified
crate::Dgeneric decimal type:D462<S>isD<crate::wide_int::Int1536, S>. Both spellings are interchangeable. - D616
- Scaled fixed-point decimal with 2048-bit storage. New top tier
beyond D307; supports correctly-rounded transcendentals at scale
up to 616 decimal digits. Now a type alias of the unified
crate::Dgeneric decimal type:D616<S>isD<crate::wide_int::Int2048, S>. Both spellings are interchangeable. - D924
- Scaled fixed-point decimal with 3072-bit storage. Half-width tier
between D616 and D1232; supports SCALE up to 924 digits. Now a type
alias of the unified
crate::Dgeneric decimal type:D924<S>isD<crate::wide_int::Int3072, S>. Both spellings are interchangeable. - D115s0
- D115s1
- D115s4
- D115s8
- D115s16
- D115s24
- D115s32
- D115s38
- D115s50
- D115s57
- D115s64
- D115s76
- D115s90
- D115s100
- D115s110
- D115s114
- Scale alias:
D115<114>. 1 LSB = 10^-114. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D153s0
- Scale alias:
D153<0>. 1 LSB = 1 (512-bit integer ledger). - D153s1
- D153s2
- D153s4
- D153s6
- D153s9
- D153s12
- D153s15
- D153s18
- D153s20
- D153s24
- D153s28
- D153s32
- D153s35
- Scale alias:
D153<35>. 1 LSB = 10^-35 (matches D38SCALE_REF). - D153s38
- D153s50
- D153s57
- D153s75
- Scale alias:
D153<75>. 1 LSB = 10^-75 (wide-scientific midpoint). - D153s76
- D153s100
- D153s115
- D153s140
- D153s150
- Scale alias:
D153<150>. 1 LSB = 10^-150. - D153s152
- Scale alias:
D153<152>. 1 LSB = 10^-152. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D230s0
- D230s1
- D230s6
- D230s18
- D230s38
- D230s57
- D230s75
- D230s100
- D230s115
- D230s140
- D230s153
- D230s175
- D230s200
- D230s215
- D230s225
- D230s229
- Scale alias:
D230<229>. 1 LSB = 10^-229. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D307s0
- Scale alias:
D307<0>. 1 LSB = 1 (1024-bit integer ledger). - D307s1
- D307s2
- D307s4
- D307s6
- D307s9
- D307s12
- D307s15
- D307s18
- D307s20
- D307s24
- D307s28
- D307s32
- D307s35
- Scale alias:
D307<35>. 1 LSB = 10^-35 (matches D38SCALE_REF). - D307s38
- D307s50
- D307s75
- D307s100
- D307s115
- D307s150
- Scale alias:
D307<150>. 1 LSB = 10^-150. - D307s153
- D307s200
- D307s230
- D307s275
- D307s300
- Scale alias:
D307<300>. 1 LSB = 10^-300. - D307s306
- Scale alias:
D307<306>. 1 LSB = 10^-306. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D462s0
- D462s1
- D462s18
- D462s38
- D462s75
- D462s115
- D462s153
- D462s200
- D462s230
- D462s275
- D462s307
- D462s350
- D462s400
- D462s440
- D462s460
- D462s461
- Scale alias:
D462<461>. 1 LSB = 10^-461. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D616s0
- D616s1
- D616s38
- D616s75
- D616s115
- D616s153
- D616s200
- D616s230
- D616s275
- D616s308
- D616s380
- D616s462
- D616s500
- D616s555
- D616s600
- D616s615
- Scale alias:
D616<615>. 1 LSB = 10^-615. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D924s0
- D924s1
- D924s75
- D924s153
- D924s230
- D924s307
- D924s400
- D924s461
- D924s462
- D924s500
- D924s616
- D924s700
- D924s800
- D924s860
- D924s900
- D924s920
- D924s923
- Scale alias:
D924<923>. 1 LSB = 10^-923. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1). - D1232
- Scaled fixed-point decimal with 4096-bit storage. Widest tier
shipped; supports SCALE up to 1232 digits. Now a type alias of the
unified
crate::Dgeneric decimal type:D1232<S>isD<crate::wide_int::Int4096, S>. Both spellings are interchangeable. - D1232s0
- D1232s1
- D1232s75
- D1232s153
- D1232s230
- D1232s307
- D1232s461
- D1232s616
- D1232s700
- D1232s800
- D1232s900
- D1232s924
- D1232s1000
- D1232s1100
- D1232s1180
- D1232s1220
- D1232s1230
- D1232s1231
- Scale alias:
D1232<1231>. 1 LSB = 10^-1231. Maximum supported scale (v0.4.0 cap:MAX_SCALE = name - 1).