Fix "kotlin.UninitializedPropertyAccessException: lateinit property typeTranslator has not been initialized" in Native IR serialization plugin
This commit is contained in:
+1
@@ -47,6 +47,7 @@ val BackendContext.externalSymbols: ReferenceSymbolTable get() = ir.symbols.exte
|
|||||||
internal fun BackendContext.createTypeTranslator(moduleDescriptor: ModuleDescriptor): TypeTranslator =
|
internal fun BackendContext.createTypeTranslator(moduleDescriptor: ModuleDescriptor): TypeTranslator =
|
||||||
TypeTranslator(externalSymbols, irBuiltIns.languageVersionSettings).apply {
|
TypeTranslator(externalSymbols, irBuiltIns.languageVersionSettings).apply {
|
||||||
constantValueGenerator = ConstantValueGenerator(moduleDescriptor, symbolTable = externalSymbols)
|
constantValueGenerator = ConstantValueGenerator(moduleDescriptor, symbolTable = externalSymbols)
|
||||||
|
constantValueGenerator.typeTranslator = this
|
||||||
}
|
}
|
||||||
|
|
||||||
interface IrBuilderExtension {
|
interface IrBuilderExtension {
|
||||||
|
|||||||
Reference in New Issue
Block a user