mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-16 15:53:55 +00:00
15 lines
298 B
Kotlin
15 lines
298 B
Kotlin
// "Create function 'hasNext'" "true"
|
|
class FooIterator<T> {
|
|
fun next(): Int {
|
|
throw Exception("not implemented")
|
|
}
|
|
}
|
|
class Foo<T> {
|
|
fun iterator(): FooIterator<String> {
|
|
throw Exception("not implemented")
|
|
}
|
|
}
|
|
fun foo() {
|
|
for (i: Int in Foo<caret><Int>()) { }
|
|
}
|