Files
kotlin/compiler/testData/codegen/box/diagnostics/functions/tailRecursion/recursiveCallInLambda.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

13 lines
217 B
Kotlin

// !DIAGNOSTICS: -UNUSED_PARAMETER
<!NO_TAIL_CALLS_FOUND!>tailRecursive fun foo()<!> {
bar {
<!NON_TAIL_RECURSIVE_CALL!>foo<!>()
}
}
fun bar(a: Any) {}
fun box(): String {
foo()
return "OK"
}