KT-4107 Data objects
This commit is contained in:
+16
@@ -0,0 +1,16 @@
|
||||
// !LANGUAGE: +DataObjects
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
|
||||
import java.io.Serializable
|
||||
|
||||
data <!CONFLICTING_JVM_DECLARATIONS!>object A<!> : Serializable {
|
||||
<!CONFLICTING_JVM_DECLARATIONS!>private fun readResolve(): Any<!> = this
|
||||
}
|
||||
|
||||
data object B : Serializable {
|
||||
private fun readResolve(): B = this
|
||||
}
|
||||
|
||||
data object C {
|
||||
private fun readResolve(): Any = this
|
||||
}
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
package
|
||||
|
||||
public data object A : java.io.Serializable {
|
||||
private constructor A()
|
||||
public open override /*1*/ /*synthesized*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*synthesized*/ fun hashCode(): kotlin.Int
|
||||
private final fun readResolve(): kotlin.Any
|
||||
public open override /*1*/ /*synthesized*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public data object B : java.io.Serializable {
|
||||
private constructor B()
|
||||
public open override /*1*/ /*synthesized*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*synthesized*/ fun hashCode(): kotlin.Int
|
||||
private final fun readResolve(): B
|
||||
public open override /*1*/ /*synthesized*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
public data object C {
|
||||
private constructor C()
|
||||
public open override /*1*/ /*synthesized*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
|
||||
public open override /*1*/ /*synthesized*/ fun hashCode(): kotlin.Int
|
||||
private final fun readResolve(): kotlin.Any
|
||||
public open override /*1*/ /*synthesized*/ fun toString(): kotlin.String
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user