KT-15286: Provide object member extensions in the completion

- Add extensions only when completion of static members is enabled (double ctrl + space and nonempty prefix)
- Add full import for callables with receiver in `LookupElement.decorateAsStaticMember`
This commit is contained in:
Roman Golyshev
2019-10-07 12:18:32 +03:00
committed by Roman Golyshev
parent 15613afa20
commit 6560ecc82b
31 changed files with 686 additions and 4 deletions
@@ -0,0 +1,19 @@
class T
interface Foo {
fun T.fooExtension()
val T.fooProperty: Int
}
object A : Foo {
override fun T.fooExtension() {}
override val T.fooProperty get() = 10
}
fun T.usage() {
foo<caret>
}
// INVOCATION_COUNT: 2
// EXIST: { lookupString: "fooExtension", itemText: "fooExtension" }
// EXIST: { lookupString: "fooProperty", itemText: "fooProperty" }