a8caf7c7d8
(cherry picked from commit 7999d68d812aedd5863f04b7fd2171e284b8f332)
11 lines
206 B
Kotlin
11 lines
206 B
Kotlin
|
|
fun Int.foo(inc0:Int, inc:Int = 0) = this + inc0 + inc
|
|
|
|
fun main(arg:Array<String>) {
|
|
val v = 42.foo(0)
|
|
if (v != 42) {
|
|
println("test failed v:$v expected:42")
|
|
throw Error()
|
|
}
|
|
}
|