Files
kotlin-fork/backend.native/tests/codegen/function/named.kt
T
Vasily Levchenko a8caf7c7d8 TEST: test for default parameters
(cherry picked from commit 7999d68d812aedd5863f04b7fd2171e284b8f332)
2017-01-13 13:42:02 +03:00

5 lines
115 B
Kotlin

fun foo(a:Int, b:Int) = a - b
fun main(args:Array<String>) {
if (foo(b = 24, a = 42) != 18)
throw Error()
}