[FIR] Resolve array literal argument for non-primitive-array parameter as arrayOf call in annotation calls
This allows us to properly complete array literals arguments of annotation calls fixing several false-negative type mismatch errors as well as enabling the inference of generic type arguments. #KT-59581 Fixed #KT-58883 Fixed
This commit is contained in:
committed by
Space Team
parent
e69b695efd
commit
97024d9ccb
Vendored
+2
-2
@@ -16,7 +16,7 @@ fun test1_0() {}
|
||||
@Ann1(*["a", "b"])
|
||||
fun test1_1() {}
|
||||
|
||||
@Ann1(*["a", 1, null])
|
||||
@Ann1(*<!ARGUMENT_TYPE_MISMATCH!>["a", 1, null]<!>)
|
||||
fun test1_2() {}
|
||||
|
||||
@Ann2(*[])
|
||||
@@ -36,5 +36,5 @@ annotation class AnnArray(val a: Array<String>)
|
||||
@AnnArray(<!NON_VARARG_SPREAD!>*<!>["/"])
|
||||
fun testArray() {}
|
||||
|
||||
@Ann1([""])
|
||||
@Ann1(<!ARGUMENT_TYPE_MISMATCH!>[""]<!>)
|
||||
fun testVararg() {}
|
||||
|
||||
Reference in New Issue
Block a user