scala folks: why is scala's Iterator defined with hasNext and next? Why not
trait Iterator[T] { def next: Option[T] }
I blame @extempore2
@Blaisorblade @posco @extempore2 You've still mutated the iter by calling next right? Otherwise you have pushed hasNext/next to lazy option.
-
-
@tixxit@posco@extempore2 Retract. My (bad) plan was that LazySome's by-name content could advance the iterator. -
@tixxit@posco@extempore2 My main point was "reinventing Stream is *HARD*", I've unwillingly violated my own advice and added evidence o_O - 1 more reply
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.