FIR2IR: generate synthetic members for data class only if needed
This commit is contained in:
committed by
Mikhail Glukhikh
parent
acced52384
commit
07add635eb
@@ -1,4 +1,3 @@
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
data class A(val x: Int) {
|
||||
override fun equals(other: Any?): Boolean = false
|
||||
}
|
||||
|
||||
-1
@@ -1,4 +1,3 @@
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
// TARGET_BACKEND: JVM
|
||||
|
||||
// WITH_RUNTIME
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
data class A(val x: Int) {
|
||||
override fun hashCode(): Int = -3
|
||||
}
|
||||
|
||||
-1
@@ -1,4 +1,3 @@
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
abstract class Base {
|
||||
final override fun toString() = "OK"
|
||||
final override fun hashCode() = 42
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
data class A(val x: Int) {
|
||||
override fun toString(): String = "!"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user