News for hackers. Stuff that matters.
Re:Java 21: What’s New? by erik_seaberg on Thursday August 10, 2023 @12:39PM (#37078393)
Iterator is a very simple API that lots of third party code implements, but streams rely on spliterators for concurrency. You can sort of get a spliterator from any iterable and make a stream, but it will probably do all work sequentially.
Re:Java 21: What’s New? by riku_iki on Thursday August 10, 2023 @12:43PM (#37078468)
> but streams rely on spliterators for concurrency

which I never seen anyone uses and it makes everything more complicated

they probably should've have some ParallelStream interface