diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/Fir2IrDeclarationStorage.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/Fir2IrDeclarationStorage.kt index 153c55f7afb..b5c53c4914c 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/Fir2IrDeclarationStorage.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/Fir2IrDeclarationStorage.kt @@ -933,11 +933,12 @@ class Fir2IrDeclarationStorage( } private fun IrSimpleFunction.populateOverriddenSymbols(thisReceiverOwner: IrClass) { - thisReceiverOwner.findMatchingOverriddenSymbolsFromSupertypes(components.irBuiltIns, this).forEach { - if (it is IrSimpleFunctionSymbol) { - overriddenSymbols += it + thisReceiverOwner.findMatchingOverriddenSymbolsFromSupertypes(components.irBuiltIns, this) + .filterIsInstance().let { + if (it.isNotEmpty()) { + overriddenSymbols = it + } } - } } private fun IrField.populateOverriddenSymbols(thisReceiverOwner: IrClass) {