Use known jvm binary class for package part if possible
This commit is contained in:
+4
-1
@@ -242,7 +242,10 @@ abstract class AbstractBinaryClassAnnotationAndConstantLoader<A : Any, C : Any,
|
||||
}
|
||||
}
|
||||
if (container is ProtoContainer.Package && container.source is JvmPackagePartSource) {
|
||||
return kotlinClassFinder.findKotlinClass((container.source as JvmPackagePartSource).classId)
|
||||
val jvmPackagePartSource = container.source as JvmPackagePartSource
|
||||
|
||||
return jvmPackagePartSource.knownJvmBinaryClass
|
||||
?: kotlinClassFinder.findKotlinClass(jvmPackagePartSource.classId)
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
+4
-2
@@ -27,7 +27,8 @@ class JvmPackagePartSource(
|
||||
val className: JvmClassName,
|
||||
val facadeClassName: JvmClassName?,
|
||||
override val incompatibility: IncompatibleVersionErrorData<JvmMetadataVersion>? = null,
|
||||
override val isPreReleaseInvisible: Boolean = false
|
||||
override val isPreReleaseInvisible: Boolean = false,
|
||||
val knownJvmBinaryClass: KotlinJvmBinaryClass? = null
|
||||
) : DeserializedContainerSource {
|
||||
constructor(
|
||||
kotlinClass: KotlinJvmBinaryClass,
|
||||
@@ -39,7 +40,8 @@ class JvmPackagePartSource(
|
||||
if (it.isNotEmpty()) JvmClassName.byInternalName(it) else null
|
||||
},
|
||||
incompatibility,
|
||||
isPreReleaseInvisible
|
||||
isPreReleaseInvisible,
|
||||
kotlinClass
|
||||
)
|
||||
|
||||
override val presentableString: String
|
||||
|
||||
Reference in New Issue
Block a user