FIR checker: fix REFERENCE_BY_QUALIFIED positioning strategy to consider callable reference

This commit is contained in:
Jinseong Jeon
2021-03-24 23:26:15 -07:00
committed by Mikhail Glukhikh
parent 8d8ed4cc18
commit bfc7eb7bab
116 changed files with 272 additions and 455 deletions
@@ -21,6 +21,6 @@ fun test() {
val pubMutRef: KMutableProperty1<JavaClass, Long> = JavaClass::publicMutable
val protFinRef: KProperty1<JavaClass, Double> = JavaClass::protectedFinal
val protMutRef: KMutableProperty1<JavaClass, Char> = JavaClass::protectedMutable
val privFinRef: KProperty1<JavaClass, String?> = <!UNRESOLVED_REFERENCE!>JavaClass::privateFinal<!>
val privMutRef: KMutableProperty1<JavaClass, Any?> = <!UNRESOLVED_REFERENCE!>JavaClass::privateMutable<!>
val privFinRef: KProperty1<JavaClass, String?> = JavaClass::<!UNRESOLVED_REFERENCE!>privateFinal<!>
val privMutRef: KMutableProperty1<JavaClass, Any?> = JavaClass::<!UNRESOLVED_REFERENCE!>privateMutable<!>
}
@@ -23,6 +23,6 @@ fun test() {
val pubMutRef: KMutableProperty0<Any?> = ::publicMutable
val protFinRef: KProperty<Double> = ::protectedFinal
val protMutRef: KMutableProperty<Char> = ::protectedMutable
val privFinRef: KProperty<JavaClass?> = <!UNRESOLVED_REFERENCE!>::privateFinal<!>
val privMutRef: KMutableProperty<Throwable?> = <!UNRESOLVED_REFERENCE!>::privateMutable<!>
val privFinRef: KProperty<JavaClass?> = ::<!UNRESOLVED_REFERENCE!>privateFinal<!>
val privMutRef: KMutableProperty<Throwable?> = ::<!UNRESOLVED_REFERENCE!>privateMutable<!>
}
@@ -7,5 +7,5 @@ class TestClass(var prop: Int)
open class OtherClass
fun OtherClass.test(prop: KProperty1<TestClass, Int>): Unit = throw Exception()
class OtherClass2: OtherClass() {
val result = <!INAPPLICABLE_CANDIDATE!>test<!>(<!UNRESOLVED_REFERENCE!>TestClass::result<!>)
val result = <!INAPPLICABLE_CANDIDATE!>test<!>(TestClass::<!UNRESOLVED_REFERENCE!>result<!>)
}