On Wed, Feb 3, 2016 at 4:20 AM, Tagir F. Valeev <amae...@gmail.com> wrote:

> Some more thoughts about forEachRemaining:
>
> To me it seems that
> if ((a = lst.elementData) != null)
> is a redundant check as well as in current ArrayList implementation
> elementData is never null. So it can be replaced with simple
> assignment.

The null check for something that is provably non-null is a sign of
the hand of Doug Lea.
I'm often tempted to try to remove them from j.u.concurrent as well,
but I resist.
They may help hotspot generate better code.

Reply via email to