KT-12152 : constructor consistency: handle non-final classes

This commit is contained in:
Mikhail Glukhikh
2015-08-11 15:35:56 +03:00
parent 8e18165065
commit f7b5d67543
7 changed files with 97 additions and 10 deletions
@@ -10,8 +10,8 @@ open class A<T> : J() {
init {
foo()
bar()
val a: Int = <!TYPE_MISMATCH!>baz()<!>
val b: T = baz()
val a: Int = <!TYPE_MISMATCH!><!DEBUG_INFO_LEAKING_THIS!>baz<!>()<!>
val b: T = <!DEBUG_INFO_LEAKING_THIS!>baz<!>()
}
fun test1() {
@@ -26,7 +26,7 @@ open class C: A() {
fun foo() = ""
init {
val a: String = foo()
val a: String = <!DEBUG_INFO_LEAKING_THIS!>foo<!>()
val b: String = bar
}
}