[IR Actualizer] Don't report errors about not implemented members from actualizer

Reporting of those errors was implemented as an ad-hock solution for part
 of the KT-58881, and it was implemented incorrectly. There won't be any
 need in this reporting in actualizer after KT-58881 will be fixed, so
 there is no actual sense to fix their implementation in actualizer itself
 (as it will be removed)
This commit is contained in:
Dmitriy Novozhilov
2023-10-16 11:51:09 +03:00
committed by Space Team
parent 2788dcb5ff
commit d5540ff035
2 changed files with 0 additions and 32 deletions
@@ -28,8 +28,6 @@ import org.jetbrains.kotlin.resolve.multiplatform.ExpectActualCompatibility
object CommonBackendErrors {
val NO_ACTUAL_FOR_EXPECT by error2<PsiElement, String, ModuleDescriptor>()
val MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED by error2<PsiElement, String, String>()
val MANY_IMPL_MEMBER_NOT_IMPLEMENTED by error2<PsiElement, String, String>()
val INCOMPATIBLE_MATCHING by error3<PsiElement, String, String, ExpectActualCompatibility.Incompatible<*>>()
val ACTUAL_ANNOTATIONS_NOT_MATCH_EXPECT by warning3<PsiElement, IrSymbol, IrSymbol, ExpectActualAnnotationsIncompatibilityType<IrConstructorCall>>()
val EVALUATION_ERROR by error1<PsiElement, String>()
@@ -48,18 +46,6 @@ object KtDefaultCommonBackendErrorMessages : BaseDiagnosticRendererFactory() {
STRING,
MODULE_WITH_PLATFORM,
)
map.put(
CommonBackendErrors.MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED,
"{0} must override {1} because it inherits multiple interface methods of it",
STRING,
STRING,
)
map.put(
CommonBackendErrors.MANY_IMPL_MEMBER_NOT_IMPLEMENTED,
"{0} must override {1} because it inherits many implementations of it",
STRING,
STRING,
)
map.put(
CommonBackendErrors.INCOMPATIBLE_MATCHING,
"Expect declaration `{0}` doesn''t match actual `{1}` because {2}",
@@ -117,24 +117,6 @@ internal class ActualFakeOverridesAdder(
processedMembers.addMember(memberFromSupertype as IrOverridableDeclaration<*>)
fakeOverrideInfo.addMember(newMember)
klass.addMember(newMember)
} else {
val baseMembers = collectActualCallablesMatchingToSpecificExpect(
newMember.symbol,
processedMembers.getMembersForActual(newMember),
expectToActualClassMap,
typeSystemContext
)
val errorFactory =
if (baseMembers.all { ((it.owner as IrDeclaration).parent as IrClass).isInterface } && (memberFromSupertype.parent as IrClass).isInterface)
CommonBackendErrors.MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED
else
CommonBackendErrors.MANY_IMPL_MEMBER_NOT_IMPLEMENTED
diagnosticsReporter.at(klass).report(
errorFactory,
klass.name.asString(),
(memberFromSupertype as IrDeclarationWithName).name.asString()
)
}
}
}