FIR: Make resolution logic for local classes the same as for top-level
Run different phases through common transformers sequentially It should make code more reusable and may help with avoid common bugs
This commit is contained in:
+2
-2
@@ -6,8 +6,8 @@ fun test(x: Any) {
|
||||
if (y !is String) return
|
||||
class Local {
|
||||
init {
|
||||
x.<!UNRESOLVED_REFERENCE!>length<!>
|
||||
y.<!UNRESOLVED_REFERENCE!>length<!>
|
||||
x.length
|
||||
y.length
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+2
-2
@@ -4,7 +4,7 @@ fun f(a: Any?) {
|
||||
if (a is B) {
|
||||
class C : X(a) {
|
||||
init {
|
||||
a.<!UNRESOLVED_REFERENCE!>foo<!>()
|
||||
a.foo()
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -13,4 +13,4 @@ fun f(a: Any?) {
|
||||
interface B {
|
||||
fun foo() {}
|
||||
}
|
||||
open class X(b: B)
|
||||
open class X(b: B)
|
||||
|
||||
@@ -4,7 +4,7 @@ fun test(x: Any) {
|
||||
class LocalOuter {
|
||||
inner class Local {
|
||||
init {
|
||||
x.<!UNRESOLVED_REFERENCE!>length<!>
|
||||
x.length
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user