Remove deprecated and not stabilized primitive unsigned iterators

This commit is contained in:
Ilya Gorbunov
2022-04-08 08:01:39 +03:00
committed by Space
parent 4598552e46
commit 2303730d57
11 changed files with 18 additions and 211 deletions
@@ -43,11 +43,10 @@ internal constructor(@PublishedApi internal val storage: IntArray) : Collection<
/** Creates an iterator over the elements of the array. */
public override operator fun iterator(): kotlin.collections.Iterator<UInt> = Iterator(storage)
@Suppress("DEPRECATION_ERROR")
private class Iterator(private val array: IntArray) : UIntIterator() {
private class Iterator(private val array: IntArray) : kotlin.collections.Iterator<UInt> {
private var index = 0
override fun hasNext() = index < array.size
override fun nextUInt() = if (index < array.size) array[index++].toUInt() else throw NoSuchElementException(index.toString())
override fun next() = if (index < array.size) array[index++].toUInt() else throw NoSuchElementException(index.toString())
}
override fun contains(element: UInt): Boolean {