[FIR] Don't miss diagnostics passed to @Suppress as names = []
In these cases we have a `FirVarargArgumentsExpression` with a `FirNamedArgumentExpression` inside as its first argument, which, in turn, has a `FirArrayLiteral` argument. ^KT-62146 Fixed
This commit is contained in:
committed by
Space Team
parent
598b5dbdf4
commit
54285736d0
+4
-1
@@ -180,7 +180,10 @@ fun List<FirAnnotation>.getAnnotationByClassIds(classIds: Collection<ClassId>, s
|
||||
|
||||
fun FirExpression.unwrapVarargValue(): List<FirExpression> {
|
||||
return when (this) {
|
||||
is FirVarargArgumentsExpression -> arguments
|
||||
is FirVarargArgumentsExpression -> when (val first = arguments.firstOrNull()) {
|
||||
is FirWrappedArgumentExpression -> first.expression.unwrapVarargValue()
|
||||
else -> arguments
|
||||
}
|
||||
is FirArrayLiteral -> arguments
|
||||
else -> listOf(this)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user