Files
kotlin-fork/backend.native/tests/external/codegen/box/controlStructures/breakContinueInExpressions/kt16713.kt
T
2017-03-13 15:31:46 +03:00

30 lines
453 B
Kotlin

class MyQueue {
fun poll(): String? = null
}
class A {
val delayedQueue = MyQueue()
fun next() {
while (true) {
delayedQueue.poll() ?: break
}
while (true) {
unblock(delayedQueue.poll() ?: break)
}
while (true) {
unblock(delayedQueue.poll() ?: break)
}
}
fun unblock(p: String) {
}
}
fun box() : String {
A().next()
return "OK"
}