Files
kotlin-fork/compiler/testData/codegen/box/controlStructures/breakContinueInExpressions/kt16713.kt
T
2019-11-19 11:00:09 +03:00

31 lines
483 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
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"
}