mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-12 15:53:40 +00:00
11 lines
285 B
Kotlin
11 lines
285 B
Kotlin
// "Create function 'iterator'" "true"
|
|
class Foo<T> {
|
|
fun iterator(): Iterator<T> {
|
|
throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates.
|
|
}
|
|
}
|
|
|
|
fun foo() {
|
|
for (i: Int in Foo<Int>()) { }
|
|
}
|