| // FILE: test.kt | |
| class A { | |
| val z | |
| by | |
| Delegate { | |
| 23 | |
| } | |
| } | |
| class Delegate( | |
| val f: () -> Int | |
| ) { | |
| operator fun getValue(thisRef: Any?, property: Any): Int { | |
| return f() | |
| } | |
| } | |
| fun box() { | |
| val z0 = A().z | |
| } | |
| // EXPECTATIONS JVM | |
| // test.kt:19 box | |
| // test.kt:2 <init> | |
| // test.kt:5 <init> | |
| // test.kt:10 <init> | |
| // test.kt:11 <init> | |
| // test.kt:10 <init> | |
| // test.kt:5 <init> | |
| // test.kt:2 <init> | |
| // test.kt:19 box | |
| // test.kt:5 getZ | |
| // test.kt:14 getValue | |
| // test.kt:6 z_delegate$lambda$0 | |
| // test.kt:14 getValue | |
| // test.kt:5 getZ | |
| // test.kt:19 box | |
| // test.kt:20 box | |
| // EXPECTATIONS NATIVE | |
| // test.kt:19 box | |
| // test.kt:2 <init> | |
| // test.kt:5 <init> | |
| // test.kt:10 <init> | |
| // test.kt:11 <init> | |
| // test.kt:12 <init> | |
| // test.kt:5 <init> | |
| // test.kt:8 <init> | |
| // test.kt:19 box | |
| // test.kt:3 <get-z> | |
| // test.kt:5 <get-z> | |
| // test.kt:13 getValue | |
| // test.kt:14 getValue | |
| // test.kt:11 <get-f> | |
| // test.kt:14 getValue | |
| // test.kt:5 invoke | |
| // test.kt:6 invoke | |
| // test.kt:7 invoke | |
| // test.kt:14 getValue | |
| // test.kt:14 getValue | |
| // test.kt:15 getValue | |
| // test.kt:5 <get-z> | |
| // test.kt:7 <get-z> | |
| // test.kt:19 box | |
| // test.kt:20 box | |
| // EXPECTATIONS JS_IR | |
| // test.kt:19 box | |
| // test.kt:5 <init> | |
| // test.kt:11 <init> | |
| // test.kt:10 <init> | |
| // test.kt:2 <init> | |
| // test.kt:19 box | |
| // test.kt:14 getValue | |
| // test.kt:6 A$z$delegate$lambda | |
| // test.kt:20 box | |
| // EXPECTATIONS WASM | |
| // test.kt:19 $box (13) | |
| // test.kt:5 $A.<init> (4, 13, 4) | |
| // test.kt:11 $Delegate.<init> (4) | |
| // test.kt:12 $Delegate.<init> (1) | |
| // test.kt:5 $A.<init> (4) | |
| // test.kt:8 $A.<init> (1) | |
| // test.kt:19 $box (17) | |
| // test.kt:14 $Delegate.getValue (15) | |
| // test.kt:6 $A$z$delegate$lambda.invoke (8, 10) | |
| // test.kt:14 $Delegate.getValue (15, 8) | |
| // test.kt:19 $box (17) | |
| // test.kt:20 $box (1) |