[FIR] DATA_CLASS_OVERRIDE_CONFLICT diagnostic

This commit is contained in:
Andrey Zinovyev
2021-06-21 15:43:01 +03:00
committed by teamcityserver
parent b44785c24e
commit b36f8ed8f5
17 changed files with 93 additions and 44 deletions
@@ -1,13 +0,0 @@
interface SuperInterface
open class SuperClass
<!INCOMPATIBLE_MODIFIERS!>abstract<!> <!INCOMPATIBLE_MODIFIERS!>data<!> class Base(val x: Int)
class Derived: Base(42)
data class Nasty(val z: Int, val y: Int): Base(z)
data class Complex(val y: Int): SuperInterface, SuperClass()
data class SubData(val sss: String) : <!FINAL_SUPERTYPE!>Complex<!>(42)
@@ -1,3 +1,4 @@
// FIR_IDENTICAL
interface SuperInterface
open class SuperClass
@@ -2,4 +2,4 @@ interface T {
final fun component1(): Int = 42
}
data class A(val x: Int) : T
<!DATA_CLASS_OVERRIDE_CONFLICT!>data<!> class A(val x: Int) : T