# | Line 152 | Line 152 | import java.lang.invoke.VarHandle; | |
---|---|---|
152 | * action.accept(array[lo]); | |
153 | * tryComplete(); | |
154 | * } | |
155 | < | * } |
156 | < | * }}</pre> |
155 | > | * }}</pre> |
156 | * | |
157 | * As a further optimization, notice that the left task need not even exist. | |
158 | * Instead of creating a new one, we can continue using the original task, | |
# | Line 171 | Line 170 | import java.lang.invoke.VarHandle; | |
170 | * if (n > 0) | |
171 | * action.accept(array[lo]); | |
172 | * propagateCompletion(); | |
173 | < | * } |
175 | < | * }}</pre> |
173 | > | * }}</pre> |
174 | * | |
175 | * When pending counts can be precomputed, they can be established in | |
176 | * the constructor: |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |