GitHub user bavardage opened a pull request:
https://github.com/apache/spark/pull/21794
[SPARK-24834] use java comparison for float and double
The methods in `Utils`, `nanSafeCompareDoubles` and `nanSafeCompareFloats`
had
the same semantics as java's `java.lang.Double.compare` and
`java.lang.Float.compare`
respectively.
## What changes were proposed in this pull request?
Remove the two functions in `Utils`, and replace the call sites (only two
for each function) with the corresponding java comparison function.
## How was this patch tested?
Existing spark tests should cover this.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/bavardage/spark-1
UseJavaComparisonForFloatAndDouble
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/21794.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #21794
----
commit 43435b9cca43f1382c2e22824ac2966e774dd503
Author: Ben Duffield <bduffield@...>
Date: 2018-07-17T14:07:23Z
use java comparison for float and double
The methods in `Util`, `nanSafeCompareDoubles` and `nanSafeCompareFloats`
had
the same semantics as java's `java.lang.Double.compare` and
`java.lang.Float.compare`
respectively.
----
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]