Understanding sequential vs parallel stream spliterators in Java 8 and Java 9
问题 A question about spliterators that at first glance is not straightforward. In streams, .parallel() changes the behaviour that the stream is processed. However I was expecting the spliterators created from sequential and parallel streams to be the same. For example, in sequential streams typically, the .trySplit() is never invoked , while in parallel streams it is, in order to hand over the split spliterator to another thread. Differences between stream.spliterator() vs stream.parallel()