Minor. Rename FunctionClassDescriptor#functionKind -> functionTypeKind
This commit is needed for the following commit. There we will restore the compatibility API with Android IDEA plugin
This commit is contained in:
committed by
Space Team
parent
a14f3c8cc2
commit
bec9ad0f6b
@@ -342,8 +342,8 @@ class KotlinTypeMapper @JvmOverloads constructor(
|
||||
|
||||
if (classDescriptor is FunctionClassDescriptor) {
|
||||
if (classDescriptor.hasBigArity ||
|
||||
classDescriptor.functionKind == FunctionTypeKind.KFunction ||
|
||||
classDescriptor.functionKind == FunctionTypeKind.KSuspendFunction
|
||||
classDescriptor.functionTypeKind == FunctionTypeKind.KFunction ||
|
||||
classDescriptor.functionTypeKind == FunctionTypeKind.KSuspendFunction
|
||||
) {
|
||||
// kotlin.reflect.KFunction{n}<P1, ..., Pn, R> is mapped to kotlin.reflect.KFunction<R> (for all n), and
|
||||
// kotlin.Function{n}<P1, ..., Pn, R> is mapped to kotlin.jvm.functions.FunctionN<R> (for n > 22).
|
||||
|
||||
+4
-4
@@ -22,14 +22,14 @@ object SuspendFunctionAsSupertypeChecker : DeclarationChecker {
|
||||
val functionalSupertypes = descriptor.getAllSuperClassifiers().filterIsInstance<FunctionClassDescriptor>().toList()
|
||||
|
||||
if (functionalSupertypes.none {
|
||||
it.functionKind == FunctionTypeKind.SuspendFunction ||
|
||||
it.functionKind == FunctionTypeKind.KSuspendFunction
|
||||
it.functionTypeKind == FunctionTypeKind.SuspendFunction ||
|
||||
it.functionTypeKind == FunctionTypeKind.KSuspendFunction
|
||||
}
|
||||
) return
|
||||
|
||||
if (functionalSupertypes.any {
|
||||
it.functionKind == FunctionTypeKind.Function ||
|
||||
it.functionKind == FunctionTypeKind.KFunction
|
||||
it.functionTypeKind == FunctionTypeKind.Function ||
|
||||
it.functionTypeKind == FunctionTypeKind.KFunction
|
||||
}
|
||||
) {
|
||||
val reportOn = (declaration as? KtClassOrObject)?.getSuperTypeList() ?: declaration
|
||||
|
||||
Reference in New Issue
Block a user