Fix using qualified this with labeled function literals

#KT-9251 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2017-04-17 05:18:17 +03:00
parent b17b3f4c63
commit b60efab62e
4 changed files with 35 additions and 12 deletions
@@ -0,0 +1,17 @@
// !DIAGNOSTICS: -UNUSED_VARIABLE
val funLit = lambda@ fun String.() {
val d1 = this@lambda
}
fun test() {
val funLit = lambda@ fun String.(): String {
return this@lambda
}
}
fun lambda() {
val funLit = lambda@ fun String.(): String {
return <!NO_THIS!>this@lambda<!>
}
}
@@ -0,0 +1,5 @@
package
public val funLit: kotlin.String.() -> kotlin.Unit
public fun lambda(): kotlin.Unit
public fun test(): kotlin.Unit