--- old/src/share/classes/java/util/OptionalInt.java 2013-12-03 14:17:04.717080264 -0800 +++ new/src/share/classes/java/util/OptionalInt.java 2013-12-03 14:17:04.493080254 -0800 @@ -31,7 +31,7 @@ /** * A container object which may or may not contain a {@code int} value. * If a value is present, {@code isPresent()} will return {@code true} and - * {@code get()} will return the value. + * {@code getAsInt()} will return the value. * *

Additional methods that depend on the presence or absence of a contained * value are provided, such as {@link #orElse(int) orElse()} @@ -39,6 +39,11 @@ * {@link #ifPresent(java.util.function.IntConsumer) ifPresent()} (execute a block * of code if the value is present). * + *

This is a value-based + * class; use of identity-sensitive operations (including reference equality + * ({@code ==}), identity hash code, or synchronization) on instances of + * {@code OptionalInt} may have unpredictable effects and should be avoided. + * * @since 1.8 */ public final class OptionalInt {