First element of a parallel stream? +possible bug report

Dmitry Bessonov dmitry.bessonov at oracle.com
Tue Dec 4 06:05:58 PST 2012


1)Question:

Is the result of the following chain of operations defined
and should be the same on all hardware/implementations?

Arrays.asList("first", "second", "last").parallel().findFirst();


2) Report: Slightly modified version throws NPE
(with the yesterday's state of the repo) :

Arrays.asList("first", "second", null, "last").parallel().findFirst();


-Dmitry


More information about the lambda-dev mailing list