https://kotlinlang.org logo
#announcements
Title
# announcements
t

trathschlag

12/11/2019, 12:48 PM
Nested, suspendable tailrec extension-functions (don't ask :)) seem to upset the compiler:
Copy code
fun test() {
    tailrec suspend fun Int.handle(): Int {
        return when {
            this <= 0 -> 0
            else -> (this - 1).handle()
        }
    }
}
=>
youtrack 1
i

Ivan Kubyshkin [JetBrains]

12/11/2019, 12:55 PM
@trathschlag Could you create an issue in https://youtrack.jetbrains.com/issues/KT? If not, I will do it for you.
t

trathschlag

12/11/2019, 12:56 PM
Will do. Just wanted to check if this is already known because I couldn't find it in YT
👍 1
2 Views