mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-18 00:21:35 +00:00
NB some cases such as captured extension receiver for an extension lambda are not supported yet; to be discussed, to what extent should we actually follow JVM code shape here.
22 lines
381 B
Kotlin
Vendored
22 lines
381 B
Kotlin
Vendored
class Receiver {
|
|
fun foo() {}
|
|
}
|
|
|
|
fun useExtensionLambda(lambda: Receiver.() -> Unit) {
|
|
}
|
|
|
|
fun test() {
|
|
useExtensionLambda {
|
|
class NamedLocal {
|
|
fun run() {
|
|
foo()
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
// JVM_TEMPLATES
|
|
// 1 final synthetic LReceiver; \$this_useExtensionLambda
|
|
|
|
// JVM_IR_TEMPLATES
|
|
// 1 private final synthetic LReceiver; \$this |