Refactoring & clarification: implement new FIR tower resolver

This commit is contained in:
Mikhail Glukhikh
2020-01-10 18:58:42 +03:00
parent a3ab763f0b
commit 14204a842a
125 changed files with 1804 additions and 1085 deletions
@@ -16,6 +16,6 @@ fun test() {
Outer.Companion::Wrapper
(Outer.Companion)::Wrapper
Outer::Wrapper
(Outer)::Wrapper
<!UNRESOLVED_REFERENCE!>Outer::Wrapper<!>
<!UNRESOLVED_REFERENCE!>(Outer)::Wrapper<!>
}
@@ -15,5 +15,5 @@ fun take(f: () -> Unit) {}
fun test() {
B::foo checkType { <!UNRESOLVED_REFERENCE!>_<!><KFunction1<B, Unit>>() }
take(B::foo)
<!INAPPLICABLE_CANDIDATE!>take<!>(B::foo)
}
@@ -18,7 +18,7 @@ import test.A
fun foo(args: Array<String>) {
val main2 = A::main
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction1<Array<String>, Unit>>(main2)
<!INAPPLICABLE_CANDIDATE!>main2<!>(args)
<!INAPPLICABLE_CANDIDATE!>(A::main)(args)<!>
checkSubtype<KFunction1<Array<String>, Unit>>(main2)
main2(args)
(A::main)(args)
}
@@ -10,7 +10,7 @@ class A {
val y = A::Nested
checkSubtype<KFunction0<Nested>>(x)
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<Nested>>(y)
checkSubtype<KFunction0<Nested>>(y)
}
companion object {
@@ -18,7 +18,7 @@ class A {
::Nested
val y = A::Nested
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<A.Nested>>(y)
checkSubtype<KFunction0<A.Nested>>(y)
}
}
}
@@ -28,6 +28,6 @@ class B {
<!UNRESOLVED_REFERENCE!>::Nested<!>
val y = A::Nested
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<A.Nested>>(y)
checkSubtype<KFunction0<A.Nested>>(y)
}
}
@@ -7,15 +7,15 @@ class A {
}
fun A.main() {
::Nested
<!UNRESOLVED_REFERENCE!>::Nested<!>
val y = A::Nested
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<A.Nested>>(y)
checkSubtype<KFunction0<A.Nested>>(y)
}
fun Int.main() {
<!UNRESOLVED_REFERENCE!>::Nested<!>
val y = A::Nested
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<A.Nested>>(y)
checkSubtype<KFunction0<A.Nested>>(y)
}
@@ -9,5 +9,5 @@ class A {
fun main() {
val x = A::Nested
<!INAPPLICABLE_CANDIDATE!>checkSubtype<!><KFunction0<A.Nested>>(x)
checkSubtype<KFunction0<A.Nested>>(x)
}