Github user srowen commented on the issue:

    https://github.com/apache/spark/pull/18156
  
    No, that's not how floating-point works. Even 0.1 as a double isn't exactly 
0.1.
    No, converting to double from float does not lose precision, but this is 
beside the point.
    3.1415 as a double is also not exactly 3.1415. I don't understand what 
you're trying to point out; of course the narrowing conversion from 3.1415d to 
float matches 3.1415f. This doesn't change the fact that the rounding answer is 
correct here. I think you are thinking of the case where you specified 3.1415 
as a decimal type.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to