You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Gen)TraversableOnce.toIterator is overridden in TraversableLike as {toStream.iterator}. But for Iterables, this should just be {iterator}.
Should be easy win, but as a motivator example, the following is inefficient (due to the intermediate Stream):
defizip[A,B](xs: TraversableOnce[A], ys: TraversableOnce[B]) =
xs.toIterator zip ys.toIterator
and must be expanded to:
defizip[A,B](xs: Iterable[A], ys: Iterable[B]) =
xs.iterator zip ys.iterator
defizip[A,B](xs: Iterator[A], ys: Iterable[B]) =
xs zip ys.iterator
defizip[A,B](xs: Iterable[A], ys: Iterator[B]) =
xs.iterator zip ys
defizip[A,B](xs: Iterator[A], ys: Iterator[B]) =
xs zip ys
// .. and more needed to handle Traversables as well
The text was updated successfully, but these errors were encountered:
(Gen)TraversableOnce.toIterator is overridden in TraversableLike as {toStream.iterator}. But for Iterables, this should just be {iterator}.
Should be easy win, but as a motivator example, the following is inefficient (due to the intermediate Stream):
and must be expanded to:
The text was updated successfully, but these errors were encountered: