Fix concrete method inheritance in interfaces
For each non-abstract non-declared (i.e. inherited from supertypes) method in an interface we generate its static form to the TImpl, which calls the TImpl method from the corresponding supertype. The accidental override tests changed because we're now trying to generate the delegate for the super method, not knowing that it will clash with the declared method #KT-2888 Fixed #KT-5393 Fixed
This commit is contained in:
+8
@@ -0,0 +1,8 @@
|
||||
interface T {
|
||||
fun getX() = 1
|
||||
}
|
||||
|
||||
interface <!CONFLICTING_JVM_DECLARATIONS!>C<!> : T {
|
||||
val x: Int
|
||||
get() = 1
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package
|
||||
|
||||
internal interface C : T {
|
||||
internal open val x: kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
internal open override /*1*/ /*fake_override*/ fun getX(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
internal interface T {
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
internal open fun getX(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
interface T {
|
||||
val x: Int
|
||||
get() = 1
|
||||
}
|
||||
|
||||
interface <!CONFLICTING_JVM_DECLARATIONS!>C<!> : T {
|
||||
fun getX() = 1
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package
|
||||
|
||||
internal interface C : T {
|
||||
internal open override /*1*/ /*fake_override*/ val x: kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
internal open fun getX(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
|
||||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
internal interface T {
|
||||
internal open val x: kotlin.Int
|
||||
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
|
||||
}
|
||||
Reference in New Issue
Block a user