diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-03-07 16:55:35 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-03-07 16:55:35 -0500 |
| commit | 60e971ff7aa31efad484cd66d4e3903ff189ef2b (patch) | |
| tree | 5d73de80d1464d52d39bb24f6820372e07031095 /stdlib | |
| parent | 7eb1fbf5d2d632bbd98fc3fa7cff777197a63d34 (diff) | |
Roll back number formatting change
Diffstat (limited to 'stdlib')
| -rw-r--r-- | stdlib/nums.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/stdlib/nums.c b/stdlib/nums.c index 6a645a37..b227ccb8 100644 --- a/stdlib/nums.c +++ b/stdlib/nums.c @@ -50,7 +50,7 @@ public CONSTFUNC bool Num$near(double a, double b, double ratio, double absolute } public Text_t Num$format(double f, Int_t precision) { - return Text$format("%.*g", (int)Int64$from_int(precision, false), f); + return Text$format("%.*f", (int)Int64$from_int(precision, false), f); } public Text_t Num$scientific(double f, Int_t precision) { @@ -125,7 +125,7 @@ public CONSTFUNC bool Num32$near(float a, float b, float ratio, float absolute) } public Text_t Num32$format(float f, Int_t precision) { - return Text$format("%.*g", (int)Int64$from_int(precision, false), (double)f); + return Text$format("%.*f", (int)Int64$from_int(precision, false), (double)f); } public Text_t Num32$scientific(float f, Int_t precision) { |
