Files
kotlin/compiler/testData/codegen/box/diagnostics/functions/tailRecursion/tailCallInParentheses.kt
Svetlana Isakova b71260f54e Moved tests
that are used both for codegen & diagnostics to codegen/box/diagnostics
2014-11-21 14:02:45 +03:00

9 lines
136 B
Kotlin

tailRecursive fun foo(x: Int) {
if (x == 0) return
return (foo(x - 1))
}
fun box(): String {
foo(1000000)
return "OK"
}