Shorten References: Skip companion receivers on callable references
This is temporary fix due to KT-13934 which prevents resolution of references like X::foo where foo is a member or extension of X companion object
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package test
|
||||
|
||||
class A {
|
||||
companion object {
|
||||
fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun A.Companion.bar() {
|
||||
|
||||
}
|
||||
|
||||
fun test() {
|
||||
<selection>A.Companion::foo
|
||||
A.Companion::bar
|
||||
(A.Companion)::foo
|
||||
(A.Companion)::bar</selection>
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package test
|
||||
|
||||
class A {
|
||||
companion object {
|
||||
fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun A.Companion.bar() {
|
||||
|
||||
}
|
||||
|
||||
fun test() {
|
||||
A.Companion::foo
|
||||
A.Companion::bar
|
||||
(A)::foo
|
||||
(A)::bar
|
||||
}
|
||||
Reference in New Issue
Block a user