FIR: check multiple vararg param and forbidden vararg type

This commit is contained in:
Tianyu Geng
2021-02-22 18:24:46 -08:00
committed by Mikhail Glukhikh
parent 0e9474342d
commit bdeecfc188
22 changed files with 130 additions and 83 deletions
@@ -1,15 +0,0 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
fun testVarargOfNothing(vararg v: Nothing) {}
fun testVarargOfNNothing(vararg v: Nothing?) {}
fun <T : Nothing?> testVarargOfT(vararg v: T) {}
fun outer() {
fun testVarargOfNothing(vararg v: Nothing) {}
fun testVarargOfNNothing(vararg v: Nothing?) {}
fun <T : Nothing?> testVarargOfT(vararg v: T) {}
}
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
// !DIAGNOSTICS: -UNUSED_PARAMETER
fun testVarargOfNothing(<!FORBIDDEN_VARARG_PARAMETER_TYPE!>vararg<!> v: Nothing) {}