diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/FakeOverrideGenerator.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/FakeOverrideGenerator.kt index cd332cc30b4..5ea6a6c8233 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/FakeOverrideGenerator.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/FakeOverrideGenerator.kt @@ -555,7 +555,6 @@ class FakeOverrideGenerator( } } - @OptIn(UnsafeDuringIrConstructionAPI::class) private fun IrProperty.setOverriddenSymbolsForProperty( declarationStorage: Fir2IrDeclarationStorage, isVar: Boolean, @@ -564,14 +563,13 @@ class FakeOverrideGenerator( val overriddenIrSymbols = getOverriddenSymbolsInSupertypes(this, firOverriddenSymbols) { declarationStorage.getIrPropertySymbol(it) as IrPropertySymbol } - val overriddenIrProperties = overriddenIrSymbols.map { it.owner } getter?.apply { - overriddenSymbols = overriddenIrProperties.mapNotNull { it.getter?.symbol } + overriddenSymbols = overriddenIrSymbols.mapNotNull { declarationStorage.findGetterOfProperty(it) } } if (isVar) { setter?.apply { - overriddenSymbols = overriddenIrProperties.mapNotNull { it.setter?.symbol } + overriddenSymbols = overriddenIrSymbols.mapNotNull { declarationStorage.findSetterOfProperty(it) } } } overriddenSymbols = overriddenIrSymbols diff --git a/compiler/testData/codegen/box/collections/removeAtIntOverrideInJava.kt b/compiler/testData/codegen/box/collections/removeAtIntOverrideInJava.kt index 74730eda968..88983dfd7a2 100644 --- a/compiler/testData/codegen/box/collections/removeAtIntOverrideInJava.kt +++ b/compiler/testData/codegen/box/collections/removeAtIntOverrideInJava.kt @@ -1,5 +1,4 @@ // TARGET_BACKEND: JVM -// IGNORE_CODEGEN_WITH_IR_FAKE_OVERRIDE_GENERATION: KT-64432 // JVM_ABI_K1_K2_DIFF: KT-57300, KT-63857 // FILE: A.java