Generate all bodies in interfaces as default methods

This commit is contained in:
Michael Bogdanov
2016-09-09 14:52:32 +03:00
parent fb48f70273
commit dfd5be1a33
5 changed files with 106 additions and 15 deletions

View File

@@ -0,0 +1,13 @@
// JVM_TARGET: 1.8
interface Z {
val z: String;
get() = "OK"
}
class Test : Z
fun box() : String {
return Test().z
}

View File

@@ -0,0 +1,15 @@
// JVM_TARGET: 1.8
interface Test {
var z: String
get() = "OK"
set(value) {}
}
// TESTED_OBJECT_KIND: function
// TESTED_OBJECTS: Test, getZ
// FLAGS: ACC_PUBLIC
// TESTED_OBJECT_KIND: function
// TESTED_OBJECTS: Test, setZ
// FLAGS: ACC_PUBLIC