FE 1.0: add deprecation ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING
#KT-45508 Fixed
This commit is contained in:
+12
@@ -16840,6 +16840,12 @@ public class FirOldFrontendDiagnosticsTestGenerated extends AbstractFirDiagnosti
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractBaseClassMemberNotImplemented_15.kt")
|
||||
public void testAbstractBaseClassMemberNotImplemented_15() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented_15.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractVsAbstract.kt")
|
||||
public void testAbstractVsAbstract() throws Exception {
|
||||
@@ -16869,6 +16875,12 @@ public class FirOldFrontendDiagnosticsTestGenerated extends AbstractFirDiagnosti
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/implementingMethodOfAny.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt45508.kt")
|
||||
public void testKt45508() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/kt45508.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("notAMethodOfAny.kt")
|
||||
public void testNotAMethodOfAny() throws Exception {
|
||||
|
||||
+12
@@ -16840,6 +16840,12 @@ public class FirOldFrontendDiagnosticsWithLightTreeTestGenerated extends Abstrac
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractBaseClassMemberNotImplemented_15.kt")
|
||||
public void testAbstractBaseClassMemberNotImplemented_15() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented_15.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractVsAbstract.kt")
|
||||
public void testAbstractVsAbstract() throws Exception {
|
||||
@@ -16869,6 +16875,12 @@ public class FirOldFrontendDiagnosticsWithLightTreeTestGenerated extends Abstrac
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/implementingMethodOfAny.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt45508.kt")
|
||||
public void testKt45508() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/kt45508.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("notAMethodOfAny.kt")
|
||||
public void testNotAMethodOfAny() throws Exception {
|
||||
|
||||
@@ -543,10 +543,14 @@ public interface Errors {
|
||||
DiagnosticFactory2.create(ERROR, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, KtClassOrObject, CallableMemberDescriptor> ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED =
|
||||
DiagnosticFactory2.create(ERROR, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, KtClassOrObject, CallableMemberDescriptor> ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING =
|
||||
DiagnosticFactory2.create(WARNING, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, KtClassOrObject, CallableMemberDescriptor> MANY_IMPL_MEMBER_NOT_IMPLEMENTED =
|
||||
DiagnosticFactory2.create(ERROR, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, KtClassOrObject, CallableMemberDescriptor> MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED =
|
||||
DiagnosticFactory2.create(ERROR, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, KtClassOrObject, CallableMemberDescriptor> MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING =
|
||||
DiagnosticFactory2.create(WARNING, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, ClassDescriptor, Collection<CallableMemberDescriptor>> INVISIBLE_ABSTRACT_MEMBER_FROM_SUPER =
|
||||
DiagnosticFactory2.create(ERROR, DECLARATION_NAME);
|
||||
DiagnosticFactory2<KtClassOrObject, ClassDescriptor, Collection<CallableMemberDescriptor>> INVISIBLE_ABSTRACT_MEMBER_FROM_SUPER_WARNING =
|
||||
|
||||
+4
@@ -853,11 +853,15 @@ public class DefaultErrorMessages {
|
||||
FQ_NAMES_IN_TYPES);
|
||||
MAP.put(ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED, "{0} is not abstract and does not implement abstract base class member {1}",
|
||||
RENDER_CLASS_OR_OBJECT, FQ_NAMES_IN_TYPES);
|
||||
MAP.put(ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING, "Deprecated: {0} is not abstract and does not implement abstract base class member {1}",
|
||||
RENDER_CLASS_OR_OBJECT, FQ_NAMES_IN_TYPES);
|
||||
|
||||
MAP.put(MANY_IMPL_MEMBER_NOT_IMPLEMENTED, "{0} must override {1} because it inherits many implementations of it",
|
||||
RENDER_CLASS_OR_OBJECT, FQ_NAMES_IN_TYPES);
|
||||
MAP.put(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED, "{0} must override {1} because it inherits multiple interface methods of it",
|
||||
RENDER_CLASS_OR_OBJECT, FQ_NAMES_IN_TYPES);
|
||||
MAP.put(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING, "Deprecated: {0} must override {1} because it inherits multiple interface methods of it",
|
||||
RENDER_CLASS_OR_OBJECT, FQ_NAMES_IN_TYPES);
|
||||
MAP.put(INVISIBLE_ABSTRACT_MEMBER_FROM_SUPER, "{0} inherits invisible abstract members: {1}", NAME, commaSeparated(FQ_NAMES_IN_TYPES));
|
||||
MAP.put(INVISIBLE_ABSTRACT_MEMBER_FROM_SUPER_WARNING, "{0} inherits invisible abstract members: {1}", NAME, commaSeparated(FQ_NAMES_IN_TYPES));
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@ import com.intellij.util.SmartList
|
||||
import com.intellij.util.containers.ContainerUtil
|
||||
import com.intellij.util.containers.SmartHashSet
|
||||
import org.jetbrains.kotlin.config.LanguageFeature
|
||||
import org.jetbrains.kotlin.config.LanguageFeature.AbstractClassMemberNotImplementedWithIntermediateAbstractClass
|
||||
import org.jetbrains.kotlin.config.LanguageVersionSettings
|
||||
import org.jetbrains.kotlin.descriptors.*
|
||||
import org.jetbrains.kotlin.descriptors.CallableMemberDescriptor.Kind.DELEGATION
|
||||
@@ -38,10 +39,7 @@ import org.jetbrains.kotlin.psi.*
|
||||
import org.jetbrains.kotlin.resolve.DescriptorUtils.classCanHaveAbstractFakeOverride
|
||||
import org.jetbrains.kotlin.resolve.OverridingUtil.OverrideCompatibilityInfo.Result.OVERRIDABLE
|
||||
import org.jetbrains.kotlin.resolve.calls.callResolverUtil.isOrOverridesSynthesized
|
||||
import org.jetbrains.kotlin.resolve.descriptorUtil.getKotlinTypeRefiner
|
||||
import org.jetbrains.kotlin.resolve.descriptorUtil.module
|
||||
import org.jetbrains.kotlin.types.*
|
||||
import org.jetbrains.kotlin.types.checker.KotlinTypeChecker
|
||||
import org.jetbrains.kotlin.types.checker.KotlinTypeRefiner
|
||||
import org.jetbrains.kotlin.types.checker.NewKotlinTypeCheckerImpl
|
||||
import org.jetbrains.kotlin.types.refinement.TypeRefinement
|
||||
@@ -128,20 +126,50 @@ class OverrideResolver(
|
||||
}
|
||||
}
|
||||
|
||||
private inner class CollectErrorInformationForInheritedMembersStrategy(
|
||||
private val klass: KtClassOrObject,
|
||||
private val classDescriptor: ClassDescriptor
|
||||
private inner class CollectWarningInformationForInheritedMembersStrategy(
|
||||
klass: KtClassOrObject,
|
||||
classDescriptor: ClassDescriptor
|
||||
) : CollectErrorInformationForInheritedMembersStrategy(klass, classDescriptor) {
|
||||
constructor(delegateStrategy: CollectErrorInformationForInheritedMembersStrategy) :
|
||||
this(delegateStrategy.klass, delegateStrategy.classDescriptor)
|
||||
|
||||
override fun doReportErrors() {
|
||||
val canHaveAbstractMembers = classCanHaveAbstractFakeOverride(classDescriptor)
|
||||
if (abstractInBaseClassNoImpl.isNotEmpty() && !canHaveAbstractMembers) {
|
||||
if (languageVersionSettings.supportsFeature(AbstractClassMemberNotImplementedWithIntermediateAbstractClass)) {
|
||||
trace.report(ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED.on(klass, klass, abstractInBaseClassNoImpl.first()))
|
||||
} else {
|
||||
trace.report(ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING.on(klass, klass, abstractInBaseClassNoImpl.first()))
|
||||
}
|
||||
}
|
||||
if (conflictingInterfaceMembers.isNotEmpty()) {
|
||||
val interfaceMember = conflictingInterfaceMembers.first()
|
||||
if (languageVersionSettings.supportsFeature(AbstractClassMemberNotImplementedWithIntermediateAbstractClass)) {
|
||||
trace.report(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED.on(klass, klass, interfaceMember))
|
||||
} else {
|
||||
trace.report(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING.on(klass, klass, interfaceMember))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private open inner class CollectErrorInformationForInheritedMembersStrategy(
|
||||
val klass: KtClassOrObject,
|
||||
val classDescriptor: ClassDescriptor
|
||||
) : CheckInheritedSignaturesReportStrategy, CheckOverrideReportStrategy {
|
||||
|
||||
private val abstractNoImpl = linkedSetOf<CallableMemberDescriptor>()
|
||||
private val abstractInBaseClassNoImpl = linkedSetOf<CallableMemberDescriptor>()
|
||||
protected val abstractInBaseClassNoImpl = linkedSetOf<CallableMemberDescriptor>()
|
||||
private val abstractInvisibleSuper = linkedSetOf<CallableMemberDescriptor>()
|
||||
private val multipleImplementations = linkedSetOf<CallableMemberDescriptor>()
|
||||
private val conflictingInterfaceMembers = linkedSetOf<CallableMemberDescriptor>()
|
||||
protected val conflictingInterfaceMembers = linkedSetOf<CallableMemberDescriptor>()
|
||||
private val conflictingReturnTypes = linkedSetOf<CallableMemberDescriptor>()
|
||||
|
||||
private val onceErrorsReported = SmartHashSet<DiagnosticFactoryWithPsiElement<*, *>>()
|
||||
|
||||
fun toDeprecationStrategy() =
|
||||
CollectWarningInformationForInheritedMembersStrategy(this)
|
||||
|
||||
override fun abstractMemberNotImplemented(descriptor: CallableMemberDescriptor) {
|
||||
abstractNoImpl.add(descriptor)
|
||||
}
|
||||
@@ -233,7 +261,7 @@ class OverrideResolver(
|
||||
}
|
||||
}
|
||||
|
||||
internal fun doReportErrors() {
|
||||
open fun doReportErrors() {
|
||||
val canHaveAbstractMembers = classCanHaveAbstractFakeOverride(classDescriptor)
|
||||
if (abstractInBaseClassNoImpl.isNotEmpty() && !canHaveAbstractMembers) {
|
||||
trace.report(ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED.on(klass, klass, abstractInBaseClassNoImpl.first()))
|
||||
@@ -251,10 +279,10 @@ class OverrideResolver(
|
||||
|
||||
conflictingInterfaceMembers.removeAll(conflictingReturnTypes)
|
||||
multipleImplementations.removeAll(conflictingReturnTypes)
|
||||
if (!conflictingInterfaceMembers.isEmpty()) {
|
||||
trace.report(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED.on(klass, klass, conflictingInterfaceMembers.iterator().next()))
|
||||
} else if (!multipleImplementations.isEmpty()) {
|
||||
trace.report(MANY_IMPL_MEMBER_NOT_IMPLEMENTED.on(klass, klass, multipleImplementations.iterator().next()))
|
||||
if (conflictingInterfaceMembers.isNotEmpty()) {
|
||||
trace.report(MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED.on(klass, klass, conflictingInterfaceMembers.first()))
|
||||
} else if (multipleImplementations.isNotEmpty()) {
|
||||
trace.report(MANY_IMPL_MEMBER_NOT_IMPLEMENTED.on(klass, klass, multipleImplementations.first()))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -342,7 +370,7 @@ class OverrideResolver(
|
||||
}
|
||||
})
|
||||
} else if (!overriddenDescriptors.isEmpty() && !overridesBackwardCompatibilityHelper.overrideCanBeOmitted(declared)) {
|
||||
val overridden = overriddenDescriptors.iterator().next()
|
||||
val overridden = overriddenDescriptors.first()
|
||||
trace.report(VIRTUAL_MEMBER_HIDDEN.on(member, declared, overridden, overridden.containingDeclaration))
|
||||
}
|
||||
}
|
||||
@@ -576,19 +604,11 @@ class OverrideResolver(
|
||||
}
|
||||
}
|
||||
|
||||
private fun checkInheritedAndDelegatedSignatures(
|
||||
descriptor: CallableMemberDescriptor,
|
||||
reportingStrategy: CheckInheritedSignaturesReportStrategy,
|
||||
overrideReportStrategyForDelegates: CheckOverrideReportStrategy?,
|
||||
kotlinTypeRefiner: KotlinTypeRefiner
|
||||
) {
|
||||
val kind = descriptor.kind
|
||||
if (kind != FAKE_OVERRIDE && kind != DELEGATION) return
|
||||
|
||||
val directOverridden = descriptor.overriddenDescriptors
|
||||
private fun CallableMemberDescriptor.computeRelevantDirectlyOverridden(): Set<CallableMemberDescriptor> {
|
||||
val directOverridden = overriddenDescriptors
|
||||
|
||||
// directOverridden may be empty if user tries to delegate implementation of abstract class instead of interface
|
||||
if (directOverridden.isEmpty()) return
|
||||
if (directOverridden.isEmpty()) return emptySet()
|
||||
|
||||
// collects map from the directly overridden descriptor to the set of declarations:
|
||||
// -- if directly overridden is not fake, the set consists of one element: this directly overridden
|
||||
@@ -600,8 +620,20 @@ class OverrideResolver(
|
||||
Sets.newLinkedHashSet(allOverriddenDeclarations)
|
||||
)
|
||||
|
||||
val relevantDirectlyOverridden =
|
||||
getRelevantDirectlyOverridden(overriddenDeclarationsByDirectParent, allFilteredOverriddenDeclarations)
|
||||
return getRelevantDirectlyOverridden(overriddenDeclarationsByDirectParent, allFilteredOverriddenDeclarations)
|
||||
}
|
||||
|
||||
private fun checkInheritedAndDelegatedSignatures(
|
||||
descriptor: CallableMemberDescriptor,
|
||||
reportingStrategy: CheckInheritedSignaturesReportStrategy,
|
||||
overrideReportStrategyForDelegates: CheckOverrideReportStrategy?,
|
||||
kotlinTypeRefiner: KotlinTypeRefiner
|
||||
) {
|
||||
val kind = descriptor.kind
|
||||
if (kind != FAKE_OVERRIDE && kind != DELEGATION) return
|
||||
|
||||
val relevantDirectlyOverridden = descriptor.computeRelevantDirectlyOverridden()
|
||||
if (relevantDirectlyOverridden.isEmpty()) return
|
||||
|
||||
if (descriptor.visibility === DescriptorVisibilities.INVISIBLE_FAKE) {
|
||||
checkInvisibleFakeOverride(descriptor, relevantDirectlyOverridden, reportingStrategy)
|
||||
@@ -622,9 +654,7 @@ class OverrideResolver(
|
||||
.filter { !isOrOverridesSynthesized(it) }
|
||||
.partition { it.modality != Modality.ABSTRACT }
|
||||
|
||||
val numImplementations = concreteOverridden.size
|
||||
|
||||
when (numImplementations) {
|
||||
when (concreteOverridden.size) {
|
||||
0 ->
|
||||
if (kind != DELEGATION) {
|
||||
abstractOverridden.forEach {
|
||||
@@ -664,7 +694,9 @@ class OverrideResolver(
|
||||
|
||||
private fun checkMissingOverridesByJava8Restrictions(
|
||||
relevantDirectlyOverridden: Set<CallableMemberDescriptor>,
|
||||
reportingStrategy: CheckInheritedSignaturesReportStrategy
|
||||
reportingStrategy: CheckInheritedSignaturesReportStrategy,
|
||||
onlyBaseClassMembers: Boolean = false,
|
||||
overriddenInterfaceMembers: MutableList<CallableMemberDescriptor> = SmartList()
|
||||
) {
|
||||
// Java 8:
|
||||
// -- class should implement an abstract member of a super-class,
|
||||
@@ -675,31 +707,53 @@ class OverrideResolver(
|
||||
var overridesClassMember = false
|
||||
var overridesNonAbstractInterfaceMember = false
|
||||
var overridesAbstractInBaseClass: CallableMemberDescriptor? = null
|
||||
val overriddenInterfaceMembers = SmartList<CallableMemberDescriptor>()
|
||||
var fakeOverrideInBaseClass: CallableMemberDescriptor? = null
|
||||
for (overridden in relevantDirectlyOverridden) {
|
||||
val containingDeclaration = overridden.containingDeclaration
|
||||
if (containingDeclaration is ClassDescriptor) {
|
||||
if (containingDeclaration.kind == ClassKind.CLASS) {
|
||||
overridesClassMember = true
|
||||
if (overridden.modality === Modality.ABSTRACT) {
|
||||
overridesAbstractInBaseClass = overridden
|
||||
}
|
||||
} else if (containingDeclaration.kind == ClassKind.INTERFACE) {
|
||||
overriddenInterfaceMembers.add(overridden)
|
||||
if (overridden.modality !== Modality.ABSTRACT) {
|
||||
overridesNonAbstractInterfaceMember = true
|
||||
}
|
||||
val containingDeclaration = overridden.containingDeclaration as? ClassDescriptor ?: continue
|
||||
if (containingDeclaration.kind == ClassKind.CLASS) {
|
||||
if (overridden.kind == FAKE_OVERRIDE && !containingDeclaration.isExpect) {
|
||||
// Fake override in a class in fact can mean an interface member
|
||||
// We will process it at the end
|
||||
// Note: with expect containing class, the situation is unclear, so we miss this case
|
||||
// See extendExpectedClassWithAbstractMember.kt (BaseA, BaseAImpl, DerivedA1)
|
||||
fakeOverrideInBaseClass = overridden
|
||||
}
|
||||
overridesClassMember = true
|
||||
if (overridden.modality === Modality.ABSTRACT) {
|
||||
overridesAbstractInBaseClass = overridden
|
||||
}
|
||||
} else if (containingDeclaration.kind == ClassKind.INTERFACE) {
|
||||
overriddenInterfaceMembers.add(overridden)
|
||||
if (overridden.modality !== Modality.ABSTRACT) {
|
||||
overridesNonAbstractInterfaceMember = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (overridesAbstractInBaseClass != null) {
|
||||
reportingStrategy.abstractBaseClassMemberNotImplemented(overridesAbstractInBaseClass)
|
||||
}
|
||||
if (!overridesClassMember && overridesNonAbstractInterfaceMember && overriddenInterfaceMembers.size > 1) {
|
||||
} else if (!onlyBaseClassMembers && !overridesClassMember &&
|
||||
overridesNonAbstractInterfaceMember && overriddenInterfaceMembers.size > 1
|
||||
) {
|
||||
for (member in overriddenInterfaceMembers) {
|
||||
reportingStrategy.conflictingInterfaceMemberNotImplemented(member)
|
||||
}
|
||||
} else if (fakeOverrideInBaseClass != null) {
|
||||
val newReportingStrategy = if (reportingStrategy is CollectErrorInformationForInheritedMembersStrategy) {
|
||||
reportingStrategy.toDeprecationStrategy()
|
||||
} else reportingStrategy
|
||||
checkMissingOverridesByJava8Restrictions(
|
||||
fakeOverrideInBaseClass.computeRelevantDirectlyOverridden(),
|
||||
reportingStrategy = newReportingStrategy,
|
||||
// Note: we don't report MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING
|
||||
// in case all interface members are derived from fakeOverrideInClass
|
||||
// (in this case we already have warning or error on its container)
|
||||
onlyBaseClassMembers = overriddenInterfaceMembers.isEmpty(),
|
||||
overriddenInterfaceMembers
|
||||
)
|
||||
if (newReportingStrategy is CollectWarningInformationForInheritedMembersStrategy) {
|
||||
newReportingStrategy.doReportErrors()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Vendored
+33
-1
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +AbstractClassMemberNotImplementedWithIntermediateAbstractClass
|
||||
|
||||
abstract class ALeft {
|
||||
abstract fun foo()
|
||||
}
|
||||
@@ -6,4 +8,34 @@ interface IRight {
|
||||
fun foo() {}
|
||||
}
|
||||
|
||||
class CDerived : ALeft(), IRight
|
||||
class CDerived : ALeft(), IRight
|
||||
|
||||
abstract class CAbstract : ALeft(), IRight
|
||||
|
||||
class CDerivedFromAbstract : CAbstract()
|
||||
|
||||
interface ILeft {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
abstract class AILeft : ILeft
|
||||
|
||||
// Should be ERROR
|
||||
class AILeftImpl : AILeft(), IRight
|
||||
|
||||
// Should be ERROR
|
||||
class RightLeft : ILeft, IRight
|
||||
|
||||
interface IBase {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface IBaseEx : IBase {
|
||||
override fun foo() {}
|
||||
}
|
||||
|
||||
abstract class AIBase : IBase
|
||||
|
||||
abstract class AIIntermediate : AIBase(), IBaseEx
|
||||
|
||||
class Impl : AIIntermediate()
|
||||
Vendored
+33
-1
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +AbstractClassMemberNotImplementedWithIntermediateAbstractClass
|
||||
|
||||
abstract class ALeft {
|
||||
abstract fun foo()
|
||||
}
|
||||
@@ -6,4 +8,34 @@ interface IRight {
|
||||
fun foo() {}
|
||||
}
|
||||
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class CDerived<!> : ALeft(), IRight
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class CDerived<!> : ALeft(), IRight
|
||||
|
||||
abstract class CAbstract : ALeft(), IRight
|
||||
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class CDerivedFromAbstract<!> : CAbstract()
|
||||
|
||||
interface ILeft {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
abstract class AILeft : ILeft
|
||||
|
||||
// Should be ERROR
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class AILeftImpl<!> : AILeft(), IRight
|
||||
|
||||
// Should be ERROR
|
||||
<!MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED!>class RightLeft<!> : ILeft, IRight
|
||||
|
||||
interface IBase {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface IBaseEx : IBase {
|
||||
override fun foo() {}
|
||||
}
|
||||
|
||||
abstract class AIBase : IBase
|
||||
|
||||
abstract class AIIntermediate : AIBase(), IBaseEx
|
||||
|
||||
class Impl : AIIntermediate()
|
||||
Vendored
+86
@@ -1,5 +1,37 @@
|
||||
package
|
||||
|
||||
public abstract class AIBase : IBase {
|
||||
public constructor AIBase()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class AIIntermediate : AIBase, IBaseEx {
|
||||
public constructor AIIntermediate()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class AILeft : ILeft {
|
||||
public constructor AILeft()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class AILeftImpl : AILeft, IRight {
|
||||
public constructor AILeftImpl()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class ALeft {
|
||||
public constructor ALeft()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
@@ -8,6 +40,14 @@ public abstract class ALeft {
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class CAbstract : ALeft, IRight {
|
||||
public constructor CAbstract()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class CDerived : ALeft, IRight {
|
||||
public constructor CDerived()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
@@ -16,9 +56,55 @@ public final class CDerived : ALeft, IRight {
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class CDerivedFromAbstract : CAbstract {
|
||||
public constructor CDerivedFromAbstract()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IBase {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IBaseEx : IBase {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface ILeft {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IRight {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class Impl : AIIntermediate {
|
||||
public constructor Impl()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class RightLeft : ILeft, IRight {
|
||||
public constructor RightLeft()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
|
||||
Vendored
+41
@@ -0,0 +1,41 @@
|
||||
// !LANGUAGE: -AbstractClassMemberNotImplementedWithIntermediateAbstractClass
|
||||
|
||||
abstract class ALeft {
|
||||
abstract fun foo()
|
||||
}
|
||||
|
||||
interface IRight {
|
||||
fun foo() {}
|
||||
}
|
||||
|
||||
class CDerived : ALeft(), IRight
|
||||
|
||||
abstract class CAbstract : ALeft(), IRight
|
||||
|
||||
class CDerivedFromAbstract : CAbstract()
|
||||
|
||||
interface ILeft {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
abstract class AILeft : ILeft
|
||||
|
||||
// Should be ERROR
|
||||
class AILeftImpl : AILeft(), IRight
|
||||
|
||||
// Should be ERROR
|
||||
class RightLeft : ILeft, IRight
|
||||
|
||||
interface IBase {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface IBaseEx : IBase {
|
||||
override fun foo() {}
|
||||
}
|
||||
|
||||
abstract class AIBase : IBase
|
||||
|
||||
abstract class AIIntermediate : AIBase(), IBaseEx
|
||||
|
||||
class Impl : AIIntermediate()
|
||||
Vendored
+41
@@ -0,0 +1,41 @@
|
||||
// !LANGUAGE: -AbstractClassMemberNotImplementedWithIntermediateAbstractClass
|
||||
|
||||
abstract class ALeft {
|
||||
abstract fun foo()
|
||||
}
|
||||
|
||||
interface IRight {
|
||||
fun foo() {}
|
||||
}
|
||||
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class CDerived<!> : ALeft(), IRight
|
||||
|
||||
abstract class CAbstract : ALeft(), IRight
|
||||
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING!>class CDerivedFromAbstract<!> : CAbstract()
|
||||
|
||||
interface ILeft {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
abstract class AILeft : ILeft
|
||||
|
||||
// Should be ERROR
|
||||
<!ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED!>class AILeftImpl<!> : AILeft(), IRight
|
||||
|
||||
// Should be ERROR
|
||||
<!MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED!>class RightLeft<!> : ILeft, IRight
|
||||
|
||||
interface IBase {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface IBaseEx : IBase {
|
||||
override fun foo() {}
|
||||
}
|
||||
|
||||
abstract class AIBase : IBase
|
||||
|
||||
abstract class AIIntermediate : AIBase(), IBaseEx
|
||||
|
||||
class Impl : AIIntermediate()
|
||||
Vendored
+110
@@ -0,0 +1,110 @@
|
||||
package
|
||||
|
||||
public abstract class AIBase : IBase {
|
||||
public constructor AIBase()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class AIIntermediate : AIBase, IBaseEx {
|
||||
public constructor AIIntermediate()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class AILeft : ILeft {
|
||||
public constructor AILeft()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class AILeftImpl : AILeft, IRight {
|
||||
public constructor AILeftImpl()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class ALeft {
|
||||
public constructor ALeft()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public abstract class CAbstract : ALeft, IRight {
|
||||
public constructor CAbstract()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class CDerived : ALeft, IRight {
|
||||
public constructor CDerived()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class CDerivedFromAbstract : CAbstract {
|
||||
public constructor CDerivedFromAbstract()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IBase {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IBaseEx : IBase {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface ILeft {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface IRight {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class Impl : AIIntermediate {
|
||||
public constructor Impl()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class RightLeft : ILeft, IRight {
|
||||
public constructor RightLeft()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.Unit
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
interface A {
|
||||
fun foo(): Any
|
||||
}
|
||||
|
||||
interface B {
|
||||
fun foo(): String = "A"
|
||||
}
|
||||
|
||||
open class D: B
|
||||
|
||||
open class C: D(), A
|
||||
|
||||
// ------------
|
||||
|
||||
class Test: Impl(), CProvider
|
||||
|
||||
open class CC
|
||||
|
||||
class DD: CC()
|
||||
|
||||
interface CProvider {
|
||||
fun getC(): CC
|
||||
}
|
||||
|
||||
interface DProvider {
|
||||
fun getC(): DD = DD()
|
||||
}
|
||||
|
||||
open class Impl: DProvider
|
||||
@@ -0,0 +1,29 @@
|
||||
interface A {
|
||||
fun foo(): Any
|
||||
}
|
||||
|
||||
interface B {
|
||||
fun foo(): String = "A"
|
||||
}
|
||||
|
||||
open class D: B
|
||||
|
||||
open <!MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING!>class C<!>: D(), A
|
||||
|
||||
// ------------
|
||||
|
||||
<!MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING!>class Test<!>: Impl(), CProvider
|
||||
|
||||
open class CC
|
||||
|
||||
class DD: CC()
|
||||
|
||||
interface CProvider {
|
||||
fun getC(): CC
|
||||
}
|
||||
|
||||
interface DProvider {
|
||||
fun getC(): DD = DD()
|
||||
}
|
||||
|
||||
open class Impl: DProvider
|
||||
@@ -0,0 +1,75 @@
|
||||
package
|
||||
|
||||
public interface A {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun foo(): kotlin.Any
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface B {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open fun foo(): kotlin.String
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class C : D, A {
|
||||
public constructor C()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun foo(): kotlin.String
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class CC {
|
||||
public constructor CC()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface CProvider {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public abstract fun getC(): CC
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class D : B {
|
||||
public constructor D()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun foo(): kotlin.String
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class DD : CC {
|
||||
public constructor DD()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public interface DProvider {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open fun getC(): DD
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public open class Impl : DProvider {
|
||||
public constructor Impl()
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*fake_override*/ fun getC(): DD
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public final class Test : Impl, CProvider {
|
||||
public constructor Test()
|
||||
public open override /*2*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*2*/ /*fake_override*/ fun getC(): DD
|
||||
public open override /*2*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*2*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
Generated
+12
@@ -16846,6 +16846,12 @@ public class DiagnosticTestGenerated extends AbstractDiagnosticTest {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractBaseClassMemberNotImplemented_15.kt")
|
||||
public void testAbstractBaseClassMemberNotImplemented_15() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/abstractBaseClassMemberNotImplemented_15.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("abstractVsAbstract.kt")
|
||||
public void testAbstractVsAbstract() throws Exception {
|
||||
@@ -16875,6 +16881,12 @@ public class DiagnosticTestGenerated extends AbstractDiagnosticTest {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/implementingMethodOfAny.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("kt45508.kt")
|
||||
public void testKt45508() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/java8Overrides/kt45508.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("notAMethodOfAny.kt")
|
||||
public void testNotAMethodOfAny() throws Exception {
|
||||
|
||||
@@ -204,6 +204,7 @@ enum class LanguageFeature(
|
||||
|
||||
DefinitelyNotNullTypeParameters(KOTLIN_1_6),
|
||||
ProhibitUsingNullableTypeParameterAgainstNotNullAnnotated(KOTLIN_1_6, kind = BUG_FIX),
|
||||
AbstractClassMemberNotImplementedWithIntermediateAbstractClass(KOTLIN_1_6, kind = BUG_FIX),
|
||||
|
||||
SuspendFunctionAsSupertype(KOTLIN_1_6),
|
||||
|
||||
|
||||
@@ -77,6 +77,7 @@ class QuickFixRegistrar : QuickFixContributor {
|
||||
MUST_BE_INITIALIZED_OR_BE_ABSTRACT.registerFactory(addAbstractModifierFactory)
|
||||
ABSTRACT_MEMBER_NOT_IMPLEMENTED.registerFactory(addAbstractModifierFactory)
|
||||
ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED.registerFactory(addAbstractModifierFactory)
|
||||
ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING.registerFactory(addAbstractModifierFactory)
|
||||
|
||||
MUST_BE_INITIALIZED_OR_BE_ABSTRACT.registerFactory(InitializePropertyQuickFixFactory)
|
||||
MUST_BE_INITIALIZED.registerFactory(InitializePropertyQuickFixFactory)
|
||||
@@ -213,7 +214,9 @@ class QuickFixRegistrar : QuickFixContributor {
|
||||
val implementMembersAsParametersHandler = ImplementAsConstructorParameter()
|
||||
ABSTRACT_MEMBER_NOT_IMPLEMENTED.registerActions(implementMembersHandler, implementMembersAsParametersHandler)
|
||||
ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED.registerActions(implementMembersHandler, implementMembersAsParametersHandler)
|
||||
ABSTRACT_CLASS_MEMBER_NOT_IMPLEMENTED_WARNING.registerActions(implementMembersHandler, implementMembersAsParametersHandler)
|
||||
MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED.registerActions(implementMembersHandler, implementMembersAsParametersHandler)
|
||||
MANY_INTERFACES_MEMBER_NOT_IMPLEMENTED_WARNING.registerActions(implementMembersHandler, implementMembersAsParametersHandler)
|
||||
MANY_IMPL_MEMBER_NOT_IMPLEMENTED.registerActions(implementMembersHandler)
|
||||
|
||||
VAL_WITH_SETTER.registerFactory(ChangeVariableMutabilityFix.VAL_WITH_SETTER_FACTORY)
|
||||
|
||||
Reference in New Issue
Block a user