News for hackers. Stuff that matters.
Re:Map.merge() – One method to rule them all by _old_dude_ on Sunday March 31, 2019 @03:32PM (#19537779)
It's also to separate the methods doing computation lazily (Stream) from the one doing computation eagerly (Collection). Otherwise a simple call like isEmpty() can trigger the whole computation like in Haskell.

As a user of the API, you have to wrap your code into a Stream to be lazy evaluated, the Stream being a computation monad, so you always know if a code is evaluated eagerly or lazily.

There are no comments on this comment yet.