Files
kotlin-fork/compiler/testData/diagnostics/testsWithStdLib/varargs/kt5534.kt
T
Svetlana Isakova 5b4f10e698 Made vararg parameters have Array<out T> type
instead of simply Array<T>
  #KT-1638 Fixed
  #KT-2163 Fixed
  #KT-3213 Fixed
  #KT-4172 Fixed
  #KT-5534 Fixed
2014-12-12 23:08:28 +03:00

6 lines
96 B
Kotlin

fun test() {
val p: Array<String> = array("a")
foo(*p)
}
fun foo(vararg a: String?) = a