Added static methods, nested classes and companion object from superclasses.

This commit is contained in:
Stanislav Erokhin
2015-10-01 21:00:44 +03:00
parent ace99f6c3f
commit d5dbc9638d
53 changed files with 2657 additions and 19 deletions
@@ -0,0 +1,33 @@
// !DIAGNOSTICS: -UNUSED_VARIABLE
// FILE: A.java
public class A {
int foo() {return 1;}
}
// FILE: 1.kt
fun foo() = ""
open class B: A() {
init {
val a: Int = foo()
}
}
fun test() {
fun foo() = ""
class B: A() {
init {
val a: Int = <!TYPE_MISMATCH!>foo()<!> // todo
}
}
}
class E: A() {
<!VIRTUAL_MEMBER_HIDDEN!>fun foo()<!> = A()
init {
val a: A = foo() // todo: discuss
}
}