[IR][tests] Add tests for removal-of-overridden open callable case

This commit is contained in:
Dmitriy Dolovov
2022-06-07 00:06:03 +03:00
parent 846537b367
commit 9c1c712057
18 changed files with 94 additions and 0 deletions
@@ -0,0 +1,7 @@
open class C {
open fun foo(): String = "FAIL1"
}
interface I {
fun foo(): String = "FAIL2"
}
@@ -0,0 +1,2 @@
open class C
interface I
@@ -0,0 +1,6 @@
STEP 0:
dependencies: stdlib
STEP 1:
dependencies: stdlib
modifications:
U : l1.kt.1 -> l1.kt
@@ -0,0 +1,7 @@
class C2 : C() {
override fun foo(): String = "O" // does not call super
}
class I2 : I {
override fun foo(): String = "K" // does not call super
}
@@ -0,0 +1,2 @@
STEP 0:
dependencies: stdlib, lib1
@@ -0,0 +1,3 @@
fun box(): String {
return C2().foo() + I2().foo()
}
@@ -0,0 +1,2 @@
STEP 0:
dependencies: stdlib, lib1, lib2
@@ -0,0 +1,7 @@
MODULES: lib1, lib2, main
STEP 0:
libs: lib1, lib2, main
STEP 1:
libs: lib1