Skip to content

Commit 92de0cc

Browse files
committed
use dragonbox algorithm; alternative to #18008
1 parent a36efb5 commit 92de0cc

File tree

3 files changed

+1404
-46
lines changed

3 files changed

+1404
-46
lines changed

changelog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,10 @@
7474
- `json` and `jsonutils` now serialize NaN, Inf, -Inf as strings, so that
7575
`%[NaN, -Inf]` is the string `["nan","-inf"]` instead of `[nan,-inf]` which was invalid json.
7676

77+
- `system.addFloat` now uses the "Dragonbox" algorithm, which ensures correct roundtrips of floating point
78+
numbers, that the minimum length representation of a floating point number is used and correct rounding.
79+
Use `-d:nimLegacyAddFloat` for a transition period.
80+
7781
- `strformat` is now part of `include std/prelude`.
7882

7983
- Deprecated `proc reversed*[T](a: openArray[T], first: Natural, last: int): seq[T]` in `std/algorithm`.

0 commit comments

Comments
 (0)