-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
expression: fix precision when casting float to string #9137
Conversation
Cast float32(208.867) to float64 will get float64(208.86700439), and convert the later to string will get a result with wrong precision
Codecov Report
@@ Coverage Diff @@
## master #9137 +/- ##
=========================================
- Coverage 67.21% 67.2% -0.02%
=========================================
Files 371 371
Lines 76982 76985 +3
=========================================
- Hits 51743 51737 -6
- Misses 20618 20624 +6
- Partials 4621 4624 +3
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@tiancaiamao does this fix need to be cherry-picked to release branches? |
Maybe I should do that @eurekaka |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/run-all-tests |
What problem does this PR solve?
Fix #9123
What is changed and how it works?
Cast float32(208.867) to float64 will get float64(208.86700439), and
convert the later to string will get a result with wrong precision
Check List
Tests
PTAL @XuHuaiyu @eurekaka