Stream optimization suggestions

Dan Smith daniel.smith at
Fri Dec 19 21:19:08 UTC 2014

I've submitted a couple of RFEs to support some simple optimizations on Streams.  I noticed both issues while writing some code that forced me to choose between cluttering up my straightforward, uniform Stream logic and eating the cost of linear operations that should be O(1).

JDK-8067969 Optimize Stream.count for SIZED Streams
JDK-8067971 Support optimizations for always-true and always-false Predicates

Certainly not high-priority, but would be nice for somebody working with to address someday.


More information about the core-libs-dev mailing list