FIR IDE: resolve arrayOf calls in annotations

This commit is contained in:
Jinseong Jeon
2021-09-14 10:21:10 -07:00
committed by Ilya Kirillov
parent 068e81570d
commit 35409fdb8d
8 changed files with 135 additions and 56 deletions
@@ -0,0 +1,4 @@
annotation class RequiresPermission(val anyOf: IntArray)
@RequiresPermission(anyOf = <expr>arrayOf(1, 2, 3)</expr>)
fun foo(): Int = 5
@@ -0,0 +1,3 @@
KtFunctionCall:
argumentMapping = { 1 -> (vararg elements: T), 2 -> (vararg elements: T), 3 -> (vararg elements: T) }
targetFunction = kotlin/arrayOf(vararg elements: T): kotlin.Array<T>
@@ -0,0 +1,4 @@
annotation class RequiresPermission(val anyOf: IntArray)
@RequiresPermission(anyOf = <expr>intArrayOf(1, 2, 3)</expr>)
fun foo(): Int = 5
@@ -0,0 +1,3 @@
KtFunctionCall:
argumentMapping = { 1 -> (vararg elements: kotlin.Int), 2 -> (vararg elements: kotlin.Int), 3 -> (vararg elements: kotlin.Int) }
targetFunction = kotlin/intArrayOf(vararg elements: kotlin.Int): kotlin.IntArray