-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
strformat float printing doesn't print ".0" portion [regression] #11089
Comments
This was never explicitly in the program though as far as I know. Did your libc change? |
Hmm, I definitely haven't updated my libc (glibc that ships with the OS, right?). My OS version is still RHEL 6.8. Are you not able to reproduce the same ".0" truncation? |
@Araq The regression of this behavior from stable to devel was confirmed on IRC. |
If it helps trace down this problem, in my git diff, I had also noticed the resolution reduction when printing floats in general too. Printing 1.23456789 printed something like 1.23456 instead. I can share the exact examples when I get to my PC. |
Earlier strformat printed a float 1.0 as
"1.0"
. Now it prints just"1"
.It was nice to have that ".0" portion printed that gave a clarity that the value being printed was a float.
Example
Current Output
Expected Output
Possible Solution
Additional Information
/cc @Araq @krux02
I discovered as I was rerunning all the snippets in my Nim notes with the latest devel.
git diff
highlighted all the missing ".0"'s:The text was updated successfully, but these errors were encountered: