--- jsr166/src/jsr166e/CompletableFuture.java 2013/01/02 18:20:16 1.3 +++ jsr166/src/jsr166e/CompletableFuture.java 2013/01/03 19:34:31 1.5 @@ -83,9 +83,9 @@ public class CompletableFuture implem /* * Overview: * - * 1. Non-nullness of field result (set via CAS) indicates - * done. An AltResult is used to box null as a result, as well as - * to hold exceptions. Using a single field makes completion fast + * 1. Non-nullness of field result (set via CAS) indicates done. + * An AltResult is used to box null as a result, as well as to + * hold exceptions. Using a single field makes completion fast * and simple to detect and trigger, at the expense of a lot of * encoding and decoding that infiltrates many methods. One minor * simplification relies on the (static) NIL (to box null results) @@ -287,7 +287,7 @@ public class CompletableFuture implem else if (q.thread != null && result == null) { try { ForkJoinPool.managedBlock(q); - } catch(InterruptedException ex){ + } catch (InterruptedException ex) { q.interruptControl = -1; } } @@ -320,7 +320,7 @@ public class CompletableFuture implem if (nanos <= 0L) throw new TimeoutException(); long d = System.nanoTime() + nanos; - q = new WaitNode(true, nanos, d == 0L? 1L : d); // avoid 0 + q = new WaitNode(true, nanos, d == 0L ? 1L : d); // avoid 0 } else if (!queued) queued = UNSAFE.compareAndSwapObject(this, WAITERS, @@ -338,7 +338,7 @@ public class CompletableFuture implem else if (q.thread != null && result == null) { try { ForkJoinPool.managedBlock(q); - } catch(InterruptedException ex){ + } catch (InterruptedException ex) { q.interruptControl = -1; } }