[FIR2IR] Configure Unit built-in to have kotlin.Any as a supertype
Without this change, the Unit type does not have Any members declared in its scope which breaks the expect/actual mapping (aka we cannot find actual `toString` for expect one).
This commit is contained in:
@@ -95,7 +95,10 @@ class IrBuiltInsOverFir(
|
||||
override val nothingType: IrType get() = nothing.type
|
||||
override val nothingNType: IrType by lazy { nothingType.makeNullable() }
|
||||
|
||||
private val unit by createClass(kotlinIrPackage, IdSignatureValues.unit, build = { kind = ClassKind.OBJECT; modality = Modality.FINAL })
|
||||
private val unit by createClass(kotlinIrPackage, IdSignatureValues.unit, build = { kind = ClassKind.OBJECT; modality = Modality.FINAL }) {
|
||||
configureSuperTypes()
|
||||
finalizeClassDefinition()
|
||||
}
|
||||
override val unitClass: IrClassSymbol get() = unit.klass
|
||||
override val unitType: IrType get() = unit.type
|
||||
|
||||
|
||||
Reference in New Issue
Block a user