Fixed completion for extension function after removing members for implicit receiver from scope.

This commit is contained in:
Stanislav Erokhin
2015-08-18 15:52:08 +03:00
parent a1274f91ba
commit ec43f49ab4
9 changed files with 209 additions and 77 deletions
@@ -12,4 +12,6 @@ fun f(pair: Pair<out Any, out Any>) {
// EXIST: { lookupString: "hashCode", attributes: "bold" }
// EXIST: { lookupString: "forString", attributes: "grayed" }
// EXIST: { lookupString: "forAny", attributes: "bold" }
// EXIST: { lookupString: "forT", attributes: "" }
/*TODO: { lookupString: "forT", attributes: "" }*/
// EXIST: { lookupString: "forT", attributes: "grayed" }
@@ -0,0 +1,15 @@
interface A {
fun foo(): Any
fun bar()
}
interface B: A {
override fun foo(): String
}
fun f(pair: Pair<out A, out Any>) {
if (pair.first !is B) return
pair.first.<caret>
}
/*TODO: { lookupString: "foo", "typeText":"Any", attributes: "bold" } */
// EXIST: { lookupString: "foo", "typeText":"String", attributes: "bold" }
// EXIST: { lookupString: "bar", attributes: "bold" }