Fix decompilation of types based on local classifiers
If deserializing a type with arguments based on a local class for decompiler, then just return Any type (without arguments). Previously Any constructor was used with serialized arguments, that lead to exception Note that in case of deserialization for compiler nothing changes about local-classes-based types (LocalClassifierResolverImpl is just inlined) #KT-13408 Fixed
This commit is contained in:
+1
-4
@@ -37,7 +37,6 @@ fun createKotlinJavascriptPackageFragmentProvider(
|
||||
val provider = PackageFragmentProviderImpl(packageFragments)
|
||||
|
||||
val notFoundClasses = NotFoundClasses(storageManager, module)
|
||||
val localClassResolver = LocalClassifierResolverImpl()
|
||||
|
||||
val components = DeserializationComponents(
|
||||
storageManager,
|
||||
@@ -45,7 +44,7 @@ fun createKotlinJavascriptPackageFragmentProvider(
|
||||
DeserializedClassDataFinder(provider),
|
||||
AnnotationAndConstantLoaderImpl(module, notFoundClasses, JsSerializerProtocol),
|
||||
provider,
|
||||
localClassResolver,
|
||||
LocalClassifierTypeSettings.Default,
|
||||
ErrorReporter.DO_NOTHING,
|
||||
LookupTracker.DO_NOTHING,
|
||||
DynamicTypeDeserializer,
|
||||
@@ -53,8 +52,6 @@ fun createKotlinJavascriptPackageFragmentProvider(
|
||||
notFoundClasses
|
||||
)
|
||||
|
||||
localClassResolver.setDeserializationComponents(components)
|
||||
|
||||
for (packageFragment in packageFragments) {
|
||||
packageFragment.components = components
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user