--- old/src/java.base/share/classes/java/math/BigDecimal.java 2016-05-01 15:21:30.080538869 -0700 +++ new/src/java.base/share/classes/java/math/BigDecimal.java 2016-05-01 15:21:29.916456872 -0700 @@ -1993,6 +1993,40 @@ return result; } + + /** + * Returns an approximation to the square root of {@code this} + * with rounding according to the context settings. + * + *

The preferred scale of the returned result is equal to + * {@code floor(this.scale()/2.0)}. The value of the returned + * result is always within one ulp of the exact decimal value for + * the precision in question. If the rounding mode is {@link + * RoundingMode#HALF_UP HALF_UP}, {@link RoundingMode#HALF_DOWN + * HALF_DOWN}, or {@link RoundingMode#HALF_EVEN HALF_EVEN}, the + * result is within one half an ulp of the exact decimal value. + * + *

Special case: + *

+ * + * @param mc the context to use. + * @return the square root of {@code this}. + * @throws ArithmeticException if {@code this} is less than zero. + * @throws ArithmeticException if an exact result is requested + * ({@code mc.getPrecision()==0}) and there is no finite decimal + * expansion of the exact result + * @throws ArithmeticException if + * {@code (mc.getRoundingMode()==RoundingMode.UNNECESSARY}) and + * the exact result cannot fit in {@code mc.getPrecision()} + * digits. + * @since 9 + */ + BigDecimal sqrt(MathContext mc) { + return ZERO; // Just the specification for now. + } + /** * Returns a {@code BigDecimal} whose value is * (thisn), The power is computed exactly, to