Move JVM8 box test to common

This commit is contained in:
Mikhael Bogdanov
2018-10-16 11:06:27 +02:00
parent b61608aba7
commit ac8e1a0124
110 changed files with 0 additions and 0 deletions
@@ -0,0 +1,32 @@
// TARGET_BACKEND: JVM
// FILE: Simple.java
interface Simple extends KInterface {
default String test() {
return "simple";
}
}
// FILE: main.kt
// JVM_TARGET: 1.8
interface KInterface {
fun test(): String {
return "base";
}
}
class Test : Simple {
fun bar(): String {
return super.test()
}
}
fun box(): String {
val test = Test().test()
if (test != "simple") return "fail $test"
val bar = Test().bar()
if (bar != "simple") return "fail 2 $bar"
return "OK"
}