Skip to content

Commit eb0577f

Browse files
committed
Revert change to Iterator
The additional purity in the asInstanceOf target is not needed
1 parent 34e947a commit eb0577f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

scala2-library-cc/src/scala/collection/Iterator.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1159,8 +1159,7 @@ object Iterator extends IterableFactory[Iterator] {
11591159
// If we advanced the current iterator to a ConcatIterator, merge it into this one
11601160
@tailrec def merge(): Unit =
11611161
if (current.isInstanceOf[ConcatIterator[_]]) {
1162-
val c: ConcatIterator[A] { val from: Iterator[A] }
1163-
= current.asInstanceOf
1162+
val c: ConcatIterator[A] = current.asInstanceOf
11641163
current = c.current.asInstanceOf // !!! CC unsafe op
11651164
currentHasNextChecked = c.currentHasNextChecked
11661165
if (c.tail != null) {

0 commit comments

Comments
 (0)