You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: java/kotlin-extractor/src/main/kotlin/KotlinFileExtractor.kt
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -3570,6 +3570,11 @@ open class KotlinFileExtractor(
3570
3570
logger.errorElement("Unexpected: property reference with non simple type. ${kPropertyType.classFqName?.asString()}", propertyReferenceExpr)
3571
3571
return
3572
3572
}
3573
+
val kPropertyClass = kPropertyType.classOrNull
3574
+
if (kPropertyClass ==null) {
3575
+
logger.errorElement("Cannot find class for kPropertyType. ${kPropertyType.classFqName?.asString()}", propertyReferenceExpr)
3576
+
return
3577
+
}
3573
3578
3574
3579
val locId = tw.getLocation(propertyReferenceExpr)
3575
3580
@@ -3583,7 +3588,7 @@ open class KotlinFileExtractor(
3583
3588
)
3584
3589
3585
3590
val currentDeclaration = declarationStack.peek()
3586
-
val prefix =if (kPropertyType.classOrNull!!.owner.name.asString().startsWith("KMutableProperty")) "Mutable"else""
3591
+
val prefix =if (kPropertyClass.owner.name.asString().startsWith("KMutableProperty")) "Mutable"else""
3587
3592
val baseClass = pluginContext.referenceClass(FqName("kotlin.jvm.internal.${prefix}PropertyReference${kPropertyType.arguments.size -1}"))?.owner?.typeWith()
0 commit comments