70c89a28e1
all not fixed type vars are found #KT-35626 fixed
11 lines
372 B
Kotlin
Vendored
11 lines
372 B
Kotlin
Vendored
// ERROR: Type mismatch: inferred type is Any but String was expected
|
|
// ERROR: Type mismatch: inferred type is Array<String> but Array<Any> was expected
|
|
import java.util.Arrays
|
|
|
|
class Foo {
|
|
fun test() {
|
|
val list = Arrays.asList("a", "b")
|
|
val array1: Array<Any> = list.toTypedArray()
|
|
val array2: Array<Any> = list.toTypedArray<String>()
|
|
}
|
|
} |