JDK 9 RFR of JDK-8030942: Explicitly state floating-point summation requirements on non-finite inputs (original) (raw)

Joe Darcy joe.darcy at oracle.com
Wed Jul 16 00:29:46 UTC 2014


Hello,

Please review my changes to address:

 JDK-8030942: Explicitly state floating-point summation requirements 

on non-finite inputs http://cr.openjdk.java.net/~darcy/8030942.0/

Patch below.

Thanks,

-Joe

--- old/src/share/classes/java/util/DoubleSummaryStatistics.java 2014-07-15 17:26:41.000000000 -0700 +++ new/src/share/classes/java/util/DoubleSummaryStatistics.java 2014-07-15 17:26:41.000000000 -0700 @@ -1,5 +1,5 @@ /*

@@ -143,6 +140,23 @@ * numerical sum compared to a simple summation of {@code double} * values. *

yield * more accurate results. * @@ -193,9 +207,6 @@ * Returns the arithmetic mean of values recorded, or zero if no * values have been recorded. *

@@ -203,6 +214,10 @@ * other technique to reduce the error bound in the {@link #getSum * numerical sum} used to compute the average. *

yield * more accurate results. * --- old/src/share/classes/java/util/stream/DoubleStream.java 2014-07-15 17:26:42.000000000 -0700 +++ new/src/share/classes/java/util/stream/DoubleStream.java 2014-07-15 17:26:42.000000000 -0700 @@ -1,5 +1,5 @@ /*

@@ -485,6 +482,23 @@ * numerical sum compared to a simple summation of {@code double} * values. *

@@ -555,9 +569,6 @@ * mean of elements of this stream, or an empty optional if this * stream is empty. *

@@ -565,6 +576,10 @@ * other technique to reduce the error bound in the {@link #sum * numerical sum} used to compute the average. *



More information about the core-libs-dev mailing list