jdk/src/share/classes/java/util/stream/Streams.java
changeset 19072 8f176099ec00
parent 18825 06636235cd12
child 19188 bbf287c5cd92
--- a/jdk/src/share/classes/java/util/stream/Streams.java	Tue Jul 30 15:47:35 2013 -0700
+++ b/jdk/src/share/classes/java/util/stream/Streams.java	Tue Jul 30 11:32:26 2013 +0100
@@ -681,11 +681,9 @@
             this.aSpliterator = aSpliterator;
             this.bSpliterator = bSpliterator;
             beforeSplit = true;
-            // The spliterator is unsized before splitting if a and b are
-            // sized and the sum of the estimates overflows
-            unsized = aSpliterator.hasCharacteristics(SIZED)
-                      && aSpliterator.hasCharacteristics(SIZED)
-                      && aSpliterator.estimateSize() + bSpliterator.estimateSize() < 0;
+            // The spliterator is known to be unsized before splitting if the
+            // sum of the estimates overflows.
+            unsized = aSpliterator.estimateSize() + bSpliterator.estimateSize() < 0;
         }
 
         @Override