diff -r 2ab0d0b3ecad -r 7a5c231327af jdk/src/share/classes/java/util/concurrent/atomic/AtomicIntegerFieldUpdater.java --- a/jdk/src/share/classes/java/util/concurrent/atomic/AtomicIntegerFieldUpdater.java Fri Jun 28 12:10:18 2013 +0100 +++ b/jdk/src/share/classes/java/util/concurrent/atomic/AtomicIntegerFieldUpdater.java Fri Jun 28 12:12:37 2013 +0100 @@ -37,14 +37,13 @@ import java.util.function.IntUnaryOperator; import java.util.function.IntBinaryOperator; import sun.misc.Unsafe; -import sun.reflect.CallerSensitive; -import sun.reflect.Reflection; - import java.lang.reflect.Field; import java.lang.reflect.Modifier; import java.security.AccessController; import java.security.PrivilegedExceptionAction; import java.security.PrivilegedActionException; +import sun.reflect.CallerSensitive; +import sun.reflect.Reflection; /** * A reflection-based utility that enables atomic updates to @@ -81,8 +80,10 @@ * access control */ @CallerSensitive - public static AtomicIntegerFieldUpdater newUpdater(Class tclass, String fieldName) { - return new AtomicIntegerFieldUpdaterImpl(tclass, fieldName, Reflection.getCallerClass()); + public static AtomicIntegerFieldUpdater newUpdater(Class tclass, + String fieldName) { + return new AtomicIntegerFieldUpdaterImpl + (tclass, fieldName, Reflection.getCallerClass()); } /** @@ -101,7 +102,7 @@ * @param obj An object whose field to conditionally set * @param expect the expected value * @param update the new value - * @return true if successful + * @return {@code true} if successful * @throws ClassCastException if {@code obj} is not an instance * of the class possessing the field established in the constructor */ @@ -114,14 +115,14 @@ * other calls to {@code compareAndSet} and {@code set}, but not * necessarily with respect to other changes in the field. * - *

May fail spuriously - * and does not provide ordering guarantees, so is only rarely an - * appropriate alternative to {@code compareAndSet}. + *

May fail + * spuriously and does not provide ordering guarantees, so is + * only rarely an appropriate alternative to {@code compareAndSet}. * * @param obj An object whose field to conditionally set * @param expect the expected value * @param update the new value - * @return true if successful + * @return {@code true} if successful * @throws ClassCastException if {@code obj} is not an instance * of the class possessing the field established in the constructor */ @@ -363,7 +364,8 @@ /** * Standard hotspot implementation using intrinsics */ - private static class AtomicIntegerFieldUpdaterImpl extends AtomicIntegerFieldUpdater { + private static class AtomicIntegerFieldUpdaterImpl + extends AtomicIntegerFieldUpdater { private static final Unsafe unsafe = Unsafe.getUnsafe(); private final long offset; private final Class tclass; @@ -371,8 +373,7 @@ AtomicIntegerFieldUpdaterImpl(final Class tclass, final String fieldName, - final Class caller) - { + final Class caller) { final Field field; final int modifiers; try {