Files
kotlin/compiler/testData/codegen/script/outerCapture.kts
Pavel V. Talanov ad58617753 Script refactoring, codegen tests: change test data according to semantics change
Add some new tests for uncovered cases
2015-11-19 22:57:01 +03:00

14 lines
181 B
Kotlin
Vendored

// expected: rv: 2
fun foo(l: (Int) -> Int ): Int {
return l(1)
}
fun bar(p: Int): Int {
return p + 1
}
fun main(): Int {
return foo { x -> bar(x) }
}
val rv = main()