Support for callable references in smart completion

This commit is contained in:
Valentin Kipyatkov
2015-09-30 19:56:17 +03:00
parent 3f64b25df3
commit ebf649a681
24 changed files with 241 additions and 46 deletions
@@ -0,0 +1,9 @@
fun foo(p: () -> Unit){}
fun bar() {
foo(::<caret>)
}
fun f(){}
// ELEMENT: f
@@ -0,0 +1,9 @@
fun foo(p: () -> Unit){}
fun bar() {
foo(::f)<caret>
}
fun f(){}
// ELEMENT: f
@@ -0,0 +1,12 @@
class C
fun C.extFun(s: String){}
fun foo(p: C.(String) -> Unit, c: Char){}
fun foo(p: (String) -> Unit){}
fun bar() {
foo(C::<caret>)
}
// ELEMENT: extFun
@@ -0,0 +1,12 @@
class C
fun C.extFun(s: String){}
fun foo(p: C.(String) -> Unit, c: Char){}
fun foo(p: (String) -> Unit){}
fun bar() {
foo(C::extFun, <caret>)
}
// ELEMENT: extFun