JS: Remove unsupported Enumeration declaration.
Relates to #KT-7480
This commit is contained in:
@@ -122,12 +122,6 @@ public open class LinkedHashMap<K, V>(
|
|||||||
@library
|
@library
|
||||||
public open class NoSuchElementException(message: String? = null) : Exception() {}
|
public open class NoSuchElementException(message: String? = null) : Exception() {}
|
||||||
|
|
||||||
@library
|
|
||||||
public interface Enumeration<E> {
|
|
||||||
public fun hasMoreElements(): Boolean
|
|
||||||
public fun nextElement(): E
|
|
||||||
}
|
|
||||||
|
|
||||||
@native
|
@native
|
||||||
public class Date() {
|
public class Date() {
|
||||||
public fun getTime(): Int = noImpl
|
public fun getTime(): Int = noImpl
|
||||||
|
|||||||
@@ -3,11 +3,12 @@
|
|||||||
|
|
||||||
package kotlin.collections
|
package kotlin.collections
|
||||||
|
|
||||||
import java.util.Enumeration
|
import java.util.*
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates an [Iterator] for an [Enumeration], allowing to use it in `for` loops.
|
* Creates an [Iterator] for an [Enumeration], allowing to use it in `for` loops.
|
||||||
*/
|
*/
|
||||||
|
@kotlin.jvm.JvmVersion
|
||||||
public operator fun <T> Enumeration<T>.iterator(): Iterator<T> = object : Iterator<T> {
|
public operator fun <T> Enumeration<T>.iterator(): Iterator<T> = object : Iterator<T> {
|
||||||
override fun hasNext(): Boolean = hasMoreElements()
|
override fun hasNext(): Boolean = hasMoreElements()
|
||||||
|
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ public fun <T> Iterator<T>.asSequence(): Sequence<T> = Sequence { this }.constra
|
|||||||
/**
|
/**
|
||||||
* Creates a sequence that returns all values from this enumeration. The sequence is constrained to be iterated only once.
|
* Creates a sequence that returns all values from this enumeration. The sequence is constrained to be iterated only once.
|
||||||
*/
|
*/
|
||||||
|
@kotlin.jvm.JvmVersion
|
||||||
@kotlin.internal.InlineOnly
|
@kotlin.internal.InlineOnly
|
||||||
public inline fun<T> Enumeration<T>.asSequence(): Sequence<T> = this.iterator().asSequence()
|
public inline fun<T> Enumeration<T>.asSequence(): Sequence<T> = this.iterator().asSequence()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user