mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-11 15:53:46 +00:00
13 lines
300 B
Kotlin
Vendored
13 lines
300 B
Kotlin
Vendored
// "Create member function 'FooIterator.next'" "true"
|
|
class FooIterator<T> {
|
|
operator fun hasNext(): Boolean { return false }
|
|
}
|
|
class Foo<T> {
|
|
operator fun iterator(): FooIterator<T> {
|
|
throw Exception("not implemented")
|
|
}
|
|
}
|
|
fun foo() {
|
|
for (i: Int in Foo<caret><Int>()) { }
|
|
}
|