JVM_IR KT-43066 Generate 'clone' in class implementing kotlin.Cloneable

This commit is contained in:
Dmitry Petrov
2020-10-30 15:40:33 +03:00
parent 7b4f781ea8
commit e4ba787034
11 changed files with 352 additions and 13 deletions
+19
View File
@@ -0,0 +1,19 @@
class A : Cloneable
interface I : Cloneable
interface I2 : Cloneable {
override fun clone(): Any
}
class C : I
class OC : I {
override fun clone(): OC = OC()
}
abstract class ACC : Cloneable
abstract class ACI : I
abstract class ACI2 : I2
+60
View File
@@ -0,0 +1,60 @@
@kotlin.Metadata
public final class A {
// source: 'cloneable.kt'
public method <init>(): void
public @org.jetbrains.annotations.NotNull method clone(): java.lang.Object
}
@kotlin.Metadata
public abstract class ACC {
// source: 'cloneable.kt'
public method <init>(): void
public @org.jetbrains.annotations.NotNull method clone(): java.lang.Object
}
@kotlin.Metadata
public abstract class ACI {
// source: 'cloneable.kt'
public method <init>(): void
public @org.jetbrains.annotations.NotNull method clone(): java.lang.Object
}
@kotlin.Metadata
public abstract class ACI2 {
// source: 'cloneable.kt'
public method <init>(): void
}
@kotlin.Metadata
public final class C {
// source: 'cloneable.kt'
public method <init>(): void
public @org.jetbrains.annotations.NotNull method clone(): java.lang.Object
}
@kotlin.Metadata
public final class I$DefaultImpls {
// source: 'cloneable.kt'
public static @org.jetbrains.annotations.NotNull method clone(@org.jetbrains.annotations.NotNull p0: I): java.lang.Object
public final inner class I$DefaultImpls
}
@kotlin.Metadata
public interface I {
// source: 'cloneable.kt'
public final inner class I$DefaultImpls
}
@kotlin.Metadata
public interface I2 {
// source: 'cloneable.kt'
public abstract @org.jetbrains.annotations.NotNull method clone(): java.lang.Object
}
@kotlin.Metadata
public final class OC {
// source: 'cloneable.kt'
public method <init>(): void
public @org.jetbrains.annotations.NotNull method clone(): OC
public synthetic bridge method clone(): java.lang.Object
}