NPE thrown by Stream.findFirst()/findAny() for a stream having null elements

Dmitry Bessonov dmitry.bessonov at oracle.com
Tue Oct 23 05:38:30 PDT 2012


Hello,

  For example the following lines both cause NPEs if run on the current 
implementation:

         Arrays.asStream(null, null, null).findFirst();
         Arrays.asStream(null, null, null).findAny();

-Dmitry




More information about the lambda-dev mailing list