Closed anba closed 4 months ago
If we restricted the permissible values to integer-valued Numbers less than Number.MAX_SAFE_INTEGER, then all the math should be doable in int64 space.
Right now it looks like we have integer-valued Numbers but they can exceed MAX_SAFE_INTEGER.
@ben-allen or @ryzokuken please bring this to the floor in an upcoming TG2 call.
Closed by #173
There are plans to limit
Temporal.Duration
values, details are still TBD. But we still need to decide if these limits should have an impact onIntl.DurationFormat
.The exact same issue was already discussed in #110, but that was before
Temporal
decided to reduce precision for theirTemporal.Duration
. Do we need to revisit #110?For example I'm currently using the following BigInt-based approach to correctly implement PartitionDurationFormatPattern, steps 4.j.iv.1-3:
This approach ensures the precise results are computed for inputs like:
Also see #110 and #151.