--- old/src/share/classes/java/lang/StrictMath.java 2011-09-19 18:03:25.000000000 -0700
+++ new/src/share/classes/java/lang/StrictMath.java 2011-09-19 18:03:25.000000000 -0700
@@ -1397,6 +1397,64 @@
}
/**
+ * Returns the floating-point value adjacent to {@code d} in
+ * the direction of negative infinity. This method is
+ * semantically equivalent to {@code nextAfter(d,
+ * Double.NEGATIVE_INFINITY)}; however, a
+ * {@code nextDown} implementation may run faster than its
+ * equivalent {@code nextAfter} call.
+ *
+ *
Special Cases:
+ *
+ * - If the argument is NaN, the result is NaN.
+ *
+ *
- If the argument is negative infinity, the result is
+ * negative infinity.
+ *
+ *
- If the argument is zero, the result is
+ * {@code -Double.MIN_VALUE}
+ *
+ *
+ *
+ * @param d starting floating-point value
+ * @return The adjacent floating-point value closer to negative
+ * infinity.
+ * @since 1.8
+ */
+ public static double nextDown(double d) {
+ return Math.nextDown(d);
+ }
+
+ /**
+ * Returns the floating-point value adjacent to {@code f} in
+ * the direction of negative infinity. This method is
+ * semantically equivalent to {@code nextAfter(f,
+ * Float.NEGATIVE_INFINITY)}; however, a
+ * {@code nextDown} implementation may run faster than its
+ * equivalent {@code nextAfter} call.
+ *
+ * Special Cases:
+ *
+ * - If the argument is NaN, the result is NaN.
+ *
+ *
- If the argument is negative infinity, the result is
+ * negative infinity.
+ *
+ *
- If the argument is zero, the result is
+ * {@code -Float.MIN_VALUE}
+ *
+ *
+ *
+ * @param f starting floating-point value
+ * @return The adjacent floating-point value closer to negative
+ * infinity.
+ * @since 1.8
+ */
+ public static double nextDown(float f) {
+ return Math.nextDown(f);
+ }
+
+ /**
* Return {@code d} ×
* 2{@code scaleFactor} rounded as if performed
* by a single correctly rounded floating-point multiply to a