mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-03-12 00:21:27 +00:00
Compare commits
659 Commits
rr/mitropo
...
tsvetkov/b
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
212aea9504 | ||
|
|
5cdf053c8e | ||
|
|
3113281e2d | ||
|
|
07feb2185b | ||
|
|
697c8637ee | ||
|
|
e7f33ac051 | ||
|
|
d4605f5816 | ||
|
|
d794c9dc4d | ||
|
|
ccac23f5b2 | ||
|
|
6a699c9384 | ||
|
|
1e3019798a | ||
|
|
6985c5fd2a | ||
|
|
4e65b2fb9e | ||
|
|
31e45d4f4c | ||
|
|
cbc57351f5 | ||
|
|
0d71b7ac2c | ||
|
|
ca7169b84f | ||
|
|
ef562598ea | ||
|
|
3187bb2aa4 | ||
|
|
5c95c48c90 | ||
|
|
536c4bbab1 | ||
|
|
046030e301 | ||
|
|
8fb82c2cb7 | ||
|
|
264094861d | ||
|
|
853503d75f | ||
|
|
1a82c94979 | ||
|
|
d9fc71b8c0 | ||
|
|
3ce980fd88 | ||
|
|
6b81cc8b77 | ||
|
|
94dcff5bab | ||
|
|
f37f89a151 | ||
|
|
b5b5c8aebc | ||
|
|
3e42b9d527 | ||
|
|
21fa2bf98c | ||
|
|
50863b6985 | ||
|
|
2c1b01fcf6 | ||
|
|
3b2e1cfa39 | ||
|
|
86fe10ba44 | ||
|
|
7be5410877 | ||
|
|
d846a22e33 | ||
|
|
0392fe75fc | ||
|
|
d37b616e1f | ||
|
|
f753824429 | ||
|
|
7536da788c | ||
|
|
34174d6e7d | ||
|
|
3580c7c28c | ||
|
|
f372a0fe6c | ||
|
|
343e645282 | ||
|
|
48a9226e1c | ||
|
|
0a230905ae | ||
|
|
f179b39c70 | ||
|
|
b9b068ff63 | ||
|
|
8ba131290a | ||
|
|
1f5fa5eb7c | ||
|
|
cb936dd82e | ||
|
|
5b1d019bb0 | ||
|
|
e6bca819d4 | ||
|
|
c3b5b21845 | ||
|
|
2693664aa7 | ||
|
|
9baced20c4 | ||
|
|
5acdad29ec | ||
|
|
650f2dd713 | ||
|
|
1c564e1bd6 | ||
|
|
94967bcd00 | ||
|
|
f6e653b242 | ||
|
|
309050d956 | ||
|
|
1d3c0f56a9 | ||
|
|
25fd5cd4ac | ||
|
|
840d3975cc | ||
|
|
cfa250957a | ||
|
|
fab9ee47f9 | ||
|
|
9308525d93 | ||
|
|
787d22c93e | ||
|
|
09a111239e | ||
|
|
866e5397d9 | ||
|
|
ed80b431f0 | ||
|
|
8920e68584 | ||
|
|
41a472693a | ||
|
|
bf419bc243 | ||
|
|
d90c383287 | ||
|
|
e08b800eb9 | ||
|
|
e61960f333 | ||
|
|
de79e3bec3 | ||
|
|
f127a0f593 | ||
|
|
d7df6e1e0c | ||
|
|
28e6028af4 | ||
|
|
da12532669 | ||
|
|
b0b8d40b71 | ||
|
|
e4198466b8 | ||
|
|
eefa621c56 | ||
|
|
b94a4d9fc3 | ||
|
|
4bb670e667 | ||
|
|
1ef68dfffd | ||
|
|
5198020c29 | ||
|
|
63b7350046 | ||
|
|
77a8cf4e66 | ||
|
|
a32f901ab9 | ||
|
|
507a718632 | ||
|
|
87014f816c | ||
|
|
d798071e06 | ||
|
|
c3fc524c0d | ||
|
|
4f36697737 | ||
|
|
6cb3687d5d | ||
|
|
69ec8f2d89 | ||
|
|
c4d41f48a3 | ||
|
|
a6234eb261 | ||
|
|
19d115778b | ||
|
|
90f9b9c1c9 | ||
|
|
2d5e6bb90b | ||
|
|
efd614194b | ||
|
|
ca5e560f1f | ||
|
|
fcabd02fe8 | ||
|
|
c1609ed490 | ||
|
|
2fefa682b7 | ||
|
|
9a0e763761 | ||
|
|
34a2196295 | ||
|
|
bf009a4949 | ||
|
|
2cffbadbd5 | ||
|
|
456508a332 | ||
|
|
7243d04f58 | ||
|
|
a8db7b3ba6 | ||
|
|
f7be373711 | ||
|
|
13f7b6a22e | ||
|
|
de2b20482a | ||
|
|
6fa03297f9 | ||
|
|
c87b12ec2f | ||
|
|
032fdd63d9 | ||
|
|
6ea0c37e52 | ||
|
|
6efa7a51c6 | ||
|
|
beca7fca30 | ||
|
|
bcaa635a4e | ||
|
|
9be8c5b527 | ||
|
|
b7df9ec05a | ||
|
|
a2da00eb49 | ||
|
|
790433984b | ||
|
|
67100d5ebe | ||
|
|
5d88058928 | ||
|
|
2f55a3fa0d | ||
|
|
0f2c96c64d | ||
|
|
158013ef3a | ||
|
|
60c51476f2 | ||
|
|
0aaf29c045 | ||
|
|
b2022144e6 | ||
|
|
ee22488ab2 | ||
|
|
2c3fe8b8ec | ||
|
|
c6124f6d56 | ||
|
|
e817f919c2 | ||
|
|
285b6d28af | ||
|
|
1d90302848 | ||
|
|
1766c22f6f | ||
|
|
604c68b3a0 | ||
|
|
1ac0e8449b | ||
|
|
fd1de9b298 | ||
|
|
57b9baac53 | ||
|
|
43bb60addb | ||
|
|
7834284bec | ||
|
|
2b2f9b3386 | ||
|
|
9c6ed2ea02 | ||
|
|
dbbb999952 | ||
|
|
6a9504f26a | ||
|
|
d0affc6c6a | ||
|
|
de1b5cd056 | ||
|
|
7ab3dd04a0 | ||
|
|
ac51e5dbd1 | ||
|
|
3f5db6b86e | ||
|
|
e76f3f93f6 | ||
|
|
d3fb9cc5f3 | ||
|
|
ab20b3e083 | ||
|
|
a9444c386d | ||
|
|
30f98e6730 | ||
|
|
c3b726f10a | ||
|
|
45234c9784 | ||
|
|
f4e9acb233 | ||
|
|
90dae320c3 | ||
|
|
b795e50e61 | ||
|
|
a382bef144 | ||
|
|
4474077963 | ||
|
|
5e115c48b3 | ||
|
|
8a393ec041 | ||
|
|
901d8f3e7a | ||
|
|
5208bbcd21 | ||
|
|
7ea1700b78 | ||
|
|
2137a4b1e5 | ||
|
|
5684e694b5 | ||
|
|
da79f93c61 | ||
|
|
deb5dc1057 | ||
|
|
5239ab477c | ||
|
|
9a1d9814de | ||
|
|
2e68526b44 | ||
|
|
a1c9ee1013 | ||
|
|
955087868a | ||
|
|
66e53305bf | ||
|
|
09bb755088 | ||
|
|
cea38771f1 | ||
|
|
b607cecc2b | ||
|
|
f3e4e9b162 | ||
|
|
a017109d7d | ||
|
|
396c6377f8 | ||
|
|
9668a60151 | ||
|
|
e058c578a8 | ||
|
|
24d7d208a0 | ||
|
|
9b5b882dcb | ||
|
|
be2d6b99f6 | ||
|
|
4bfcb4b041 | ||
|
|
89c1af4feb | ||
|
|
891071e074 | ||
|
|
405412f6c1 | ||
|
|
f584fb1576 | ||
|
|
1a9f236a60 | ||
|
|
007970ded8 | ||
|
|
bd05b447c0 | ||
|
|
9468670980 | ||
|
|
64e47265e1 | ||
|
|
e822e871f5 | ||
|
|
a87b25d10e | ||
|
|
ea5fef76d1 | ||
|
|
c2c139ef4f | ||
|
|
c5a2ab2512 | ||
|
|
bc40669598 | ||
|
|
e3050cd997 | ||
|
|
94ab50a21a | ||
|
|
366a75e222 | ||
|
|
35d5936829 | ||
|
|
7ea17f0d31 | ||
|
|
0b29a3e5c1 | ||
|
|
76550d3c5d | ||
|
|
c0634217e1 | ||
|
|
59e63f549b | ||
|
|
5c70f973a5 | ||
|
|
e4c8c14e3e | ||
|
|
e43932f147 | ||
|
|
f76befa84e | ||
|
|
407d1365bd | ||
|
|
36102504a1 | ||
|
|
20ed42dd38 | ||
|
|
2fd3af73eb | ||
|
|
bc34f7f7f5 | ||
|
|
a04f70fb36 | ||
|
|
684ca5029f | ||
|
|
9844607d0f | ||
|
|
f06e116bf7 | ||
|
|
27c139926c | ||
|
|
e72a06bdf4 | ||
|
|
3f266aafb4 | ||
|
|
cbd8b58d5c | ||
|
|
1ee8e615fc | ||
|
|
c21820c615 | ||
|
|
a6f14c206b | ||
|
|
b95d3e711e | ||
|
|
034623f82a | ||
|
|
448e0ceae1 | ||
|
|
8dfcebf542 | ||
|
|
53cbcfac5a | ||
|
|
d41e8ed4ad | ||
|
|
e8659d4b37 | ||
|
|
3585f80c67 | ||
|
|
12cd3785b0 | ||
|
|
9c8904f165 | ||
|
|
990903e4e2 | ||
|
|
699829ccb3 | ||
|
|
79691feb8f | ||
|
|
027d177c15 | ||
|
|
c80cf0f34c | ||
|
|
70f0f357fa | ||
|
|
6c6b7c8b84 | ||
|
|
b62e22cb01 | ||
|
|
895c32e21c | ||
|
|
643d339496 | ||
|
|
d6483ace94 | ||
|
|
a5ae1b38b0 | ||
|
|
ab34f8c738 | ||
|
|
c6a481190a | ||
|
|
64f7c3f498 | ||
|
|
7013becda5 | ||
|
|
988226a90e | ||
|
|
014d855449 | ||
|
|
3c90e25cb4 | ||
|
|
597bc061e2 | ||
|
|
2162c39ab3 | ||
|
|
33150a0809 | ||
|
|
9e2f95233c | ||
|
|
e34246faec | ||
|
|
8044b47984 | ||
|
|
ddd03373cc | ||
|
|
6f4f7dd090 | ||
|
|
f028d6c898 | ||
|
|
64aa0ec5c8 | ||
|
|
49124709b8 | ||
|
|
e4f88e83fe | ||
|
|
2534b15553 | ||
|
|
8f6a1b418d | ||
|
|
fa221af1b1 | ||
|
|
932ce71093 | ||
|
|
b71c74c6ef | ||
|
|
0c6d485c9c | ||
|
|
9377d274a8 | ||
|
|
c386cbeb54 | ||
|
|
e57de9a08f | ||
|
|
27c52f54ca | ||
|
|
f20e878d35 | ||
|
|
f2045b857b | ||
|
|
af6ed5ca43 | ||
|
|
3155f56d8a | ||
|
|
8644c48b28 | ||
|
|
d90aba60cc | ||
|
|
7a19906705 | ||
|
|
db5046af85 | ||
|
|
a3c77eca08 | ||
|
|
ff830cc744 | ||
|
|
848ca70de1 | ||
|
|
224d56ec15 | ||
|
|
1c498660dc | ||
|
|
19495e40f7 | ||
|
|
99d823da8a | ||
|
|
c6240face0 | ||
|
|
1103de4bd5 | ||
|
|
9542eb36ec | ||
|
|
94e36411fa | ||
|
|
0c1f2edbf2 | ||
|
|
80d83f8703 | ||
|
|
38822c3bf8 | ||
|
|
ba8147cd47 | ||
|
|
5f61f6f3a5 | ||
|
|
2e0d4c9af1 | ||
|
|
30f2affb93 | ||
|
|
296f343cab | ||
|
|
a095309e10 | ||
|
|
2c93c46b84 | ||
|
|
1e82975a7c | ||
|
|
a14e8e4c28 | ||
|
|
0b0550f562 | ||
|
|
eb3ac74c3f | ||
|
|
6eae77572a | ||
|
|
e00dc76645 | ||
|
|
cf63a5f52b | ||
|
|
5791ecd4f7 | ||
|
|
cb0eb008f8 | ||
|
|
06e6c7cdf5 | ||
|
|
fe7abb7132 | ||
|
|
2f41eef797 | ||
|
|
aed78f3c9b | ||
|
|
be42ae470d | ||
|
|
2189fe5796 | ||
|
|
fd51a9a085 | ||
|
|
30e352ea27 | ||
|
|
ef4e4881b7 | ||
|
|
c9e5b6a234 | ||
|
|
520f2455b3 | ||
|
|
77978637a8 | ||
|
|
530252eea8 | ||
|
|
7e7a5fe736 | ||
|
|
ad7055b8a0 | ||
|
|
900e78b39b | ||
|
|
82acf7deb6 | ||
|
|
0400a62014 | ||
|
|
b6cf17af1b | ||
|
|
28d6752315 | ||
|
|
c45993b2b1 | ||
|
|
5c845da18a | ||
|
|
b175f46315 | ||
|
|
2310a04e4e | ||
|
|
00366197f8 | ||
|
|
6a9f4cf8b7 | ||
|
|
bab4407c0a | ||
|
|
ff6e06aa14 | ||
|
|
4d80d17b23 | ||
|
|
731fb9bc70 | ||
|
|
4c1727b82e | ||
|
|
27e2faa778 | ||
|
|
d6a45dfe75 | ||
|
|
0a70277240 | ||
|
|
18d29f7d98 | ||
|
|
aca889a95b | ||
|
|
169a2f361c | ||
|
|
6af47ad7b3 | ||
|
|
66dbd1af34 | ||
|
|
2985e8bcd3 | ||
|
|
cbc9c19faf | ||
|
|
d9279bff73 | ||
|
|
be3eb98fbd | ||
|
|
4345294ac1 | ||
|
|
d03937cdb6 | ||
|
|
792ae8d272 | ||
|
|
3ccf542b38 | ||
|
|
0ef34dcf53 | ||
|
|
a25896bf6a | ||
|
|
0839e7afdc | ||
|
|
a6cc7cdc23 | ||
|
|
5209f4a9c0 | ||
|
|
bb119280be | ||
|
|
b5778e6de5 | ||
|
|
4fdfdb9b4c | ||
|
|
06ee4ac21f | ||
|
|
9555497d5d | ||
|
|
4dc1e587b4 | ||
|
|
45555d681d | ||
|
|
3ab7c263d0 | ||
|
|
c4cc858b84 | ||
|
|
f99829ce5e | ||
|
|
178b2a07ae | ||
|
|
f8cb637712 | ||
|
|
0a76da99cf | ||
|
|
dd93deddd7 | ||
|
|
c2a70b4e57 | ||
|
|
34a59f5b85 | ||
|
|
b1dc403182 | ||
|
|
dcd8a4a4c7 | ||
|
|
aca7a49214 | ||
|
|
a20269bcdd | ||
|
|
11e808715b | ||
|
|
c3600ba114 | ||
|
|
a582d88cf4 | ||
|
|
f6373a647e | ||
|
|
a27a07ce81 | ||
|
|
e9570d6efd | ||
|
|
6b2c87020b | ||
|
|
daab07ea38 | ||
|
|
593684ecb6 | ||
|
|
e6edab1c82 | ||
|
|
e8aa14a283 | ||
|
|
5942446274 | ||
|
|
4c34e9dd03 | ||
|
|
879e22f274 | ||
|
|
83b52bb109 | ||
|
|
69e8abfe3c | ||
|
|
4e92c79bc4 | ||
|
|
d477d9eb43 | ||
|
|
5bfec7f6bc | ||
|
|
af3bda51ec | ||
|
|
41511898a1 | ||
|
|
39740ce440 | ||
|
|
d08f91bf35 | ||
|
|
6d07af63cf | ||
|
|
d02d423d45 | ||
|
|
a791a38538 | ||
|
|
987cf5ef5f | ||
|
|
0622be14a5 | ||
|
|
5e9291bd8a | ||
|
|
e6539eade5 | ||
|
|
b657d60bd6 | ||
|
|
bcd3921bae | ||
|
|
05e8546bdb | ||
|
|
abfc74c8b2 | ||
|
|
d8fa617bfd | ||
|
|
99f958c8c4 | ||
|
|
af24ce5e03 | ||
|
|
4ac7dc0744 | ||
|
|
360a5bf348 | ||
|
|
5ad94daaa5 | ||
|
|
2610dedcbd | ||
|
|
10c62b8d77 | ||
|
|
4de582564c | ||
|
|
8faced9192 | ||
|
|
383fa2d111 | ||
|
|
e7cee9c6e1 | ||
|
|
a06c8786df | ||
|
|
9313073971 | ||
|
|
793ada08a9 | ||
|
|
538cf8af56 | ||
|
|
4ad95dbe0c | ||
|
|
856ac76c8f | ||
|
|
29d3d07636 | ||
|
|
b2e70f9c21 | ||
|
|
4ecb228d50 | ||
|
|
b21cabe671 | ||
|
|
40ec794c66 | ||
|
|
852e860743 | ||
|
|
c2e97a7287 | ||
|
|
5676d31a1c | ||
|
|
b8aff0660c | ||
|
|
c9c20bb34c | ||
|
|
e9231b5624 | ||
|
|
558dfc6d9a | ||
|
|
2b2fce5949 | ||
|
|
be2ac3bb4f | ||
|
|
8ce28cb509 | ||
|
|
23dc75fb87 | ||
|
|
9d111b9451 | ||
|
|
6c8ff25e5d | ||
|
|
696701d377 | ||
|
|
7632910ffd | ||
|
|
5550dc93a1 | ||
|
|
b55729957e | ||
|
|
e9c4f531eb | ||
|
|
67044f22ed | ||
|
|
bbfc1a10ad | ||
|
|
6792779281 | ||
|
|
dfdc1e9c4f | ||
|
|
2c3d8feb26 | ||
|
|
cc818025df | ||
|
|
a493b21c7c | ||
|
|
230f2f5ce0 | ||
|
|
c638043aee | ||
|
|
130987fa1e | ||
|
|
db93462bcf | ||
|
|
d9fea52344 | ||
|
|
f7b660b573 | ||
|
|
10cae9bc5d | ||
|
|
0b7d8c51cb | ||
|
|
19ac036ec5 | ||
|
|
cb5aa64a95 | ||
|
|
48153c53ca | ||
|
|
120f77416b | ||
|
|
66a59df7de | ||
|
|
a2e4b52747 | ||
|
|
98fc4ab2e1 | ||
|
|
f2bc391bdd | ||
|
|
e8a303650c | ||
|
|
06a3376368 | ||
|
|
4dbc6803ba | ||
|
|
96ed30a449 | ||
|
|
0b2d96c1ef | ||
|
|
58dd0fa3d2 | ||
|
|
58e9b3ae0e | ||
|
|
84287d77ca | ||
|
|
1749cb9129 | ||
|
|
f4e4baa253 | ||
|
|
1ebb116056 | ||
|
|
f1955c84aa | ||
|
|
6e9efefd2a | ||
|
|
9f4569e5a1 | ||
|
|
37fbc75008 | ||
|
|
d6fc830c24 | ||
|
|
a7675c16d5 | ||
|
|
9c8e979308 | ||
|
|
58183b774d | ||
|
|
99d844dcfb | ||
|
|
16100843b2 | ||
|
|
b5ecab31f5 | ||
|
|
bd8eaad885 | ||
|
|
d01817ce14 | ||
|
|
1dfccf1416 | ||
|
|
f0cc3a32d9 | ||
|
|
64c9a83862 | ||
|
|
a317c8a803 | ||
|
|
26458875d5 | ||
|
|
25621d699b | ||
|
|
4078b4b6f9 | ||
|
|
c9bc5884dd | ||
|
|
faa0f07d09 | ||
|
|
5ecbf8b7cd | ||
|
|
05ee436db0 | ||
|
|
8a81a09fd0 | ||
|
|
4e2e05e689 | ||
|
|
12ed8c3bb4 | ||
|
|
4e6542a646 | ||
|
|
1a0df97961 | ||
|
|
3765c5119f | ||
|
|
b5cceb8995 | ||
|
|
2f8e95dace | ||
|
|
9f55d4f3cd | ||
|
|
87859b0faa | ||
|
|
950bbfe3a5 | ||
|
|
34be9e3569 | ||
|
|
65fae3bb0c | ||
|
|
5b64c0cfe2 | ||
|
|
1261f62afb | ||
|
|
3a4f53682f | ||
|
|
44f6a5adcd | ||
|
|
d119298232 | ||
|
|
b43014a097 | ||
|
|
66e23c9767 | ||
|
|
59183a8142 | ||
|
|
70ea53315d | ||
|
|
63d549dfa1 | ||
|
|
68e1acd2cb | ||
|
|
6410aed1b4 | ||
|
|
6393667dda | ||
|
|
5cad8a793c | ||
|
|
63575582c4 | ||
|
|
d5ffc7416d | ||
|
|
0ade8140f7 | ||
|
|
dbb47cf48e | ||
|
|
cd1bf563cd | ||
|
|
f0bc52222d | ||
|
|
8cb4f59114 | ||
|
|
743abea690 | ||
|
|
c3cbfe34c4 | ||
|
|
53b31a20ca | ||
|
|
94de114894 | ||
|
|
017f640f26 | ||
|
|
e93bcc55ae | ||
|
|
8bc4407be0 | ||
|
|
6c9c2a287d | ||
|
|
9c0b96af71 | ||
|
|
a150e7b6e5 | ||
|
|
929bb0e8d1 | ||
|
|
9d48ecfac3 | ||
|
|
b8f0ad2111 | ||
|
|
5bdf3d5757 | ||
|
|
477cca3c99 | ||
|
|
a98ad79d86 | ||
|
|
7a8908a75b | ||
|
|
a0cccdf75c | ||
|
|
596c3d1af8 | ||
|
|
4c878c27a9 | ||
|
|
5b48845dfa | ||
|
|
ce553f1211 | ||
|
|
48a4e08d60 | ||
|
|
efee0dae94 | ||
|
|
0bc2642634 | ||
|
|
429b2a9705 | ||
|
|
260e2d0dc3 | ||
|
|
6a28558d43 | ||
|
|
12181e55c0 | ||
|
|
955c7a1e5b | ||
|
|
781bfa20e8 | ||
|
|
b076bec07f | ||
|
|
11a680d7d8 | ||
|
|
bfedeed2c1 | ||
|
|
7df0dd5032 | ||
|
|
6e5b94f695 | ||
|
|
c923b2e139 | ||
|
|
97c688057d | ||
|
|
ba5e643cb2 | ||
|
|
bf26d87ee9 | ||
|
|
16b62b8e65 | ||
|
|
194791a168 | ||
|
|
846a7823ad | ||
|
|
a8cd8ad8f8 | ||
|
|
b100fd526f | ||
|
|
5724c47bcf | ||
|
|
542f1b8709 | ||
|
|
932cf21776 | ||
|
|
7386408e94 | ||
|
|
49dd839131 | ||
|
|
46be588f27 | ||
|
|
606fad64ad | ||
|
|
91b371789e | ||
|
|
204871a7ab | ||
|
|
754a74ac4a | ||
|
|
03bb9138ad | ||
|
|
bf1ad44af9 | ||
|
|
5fe47ffbec | ||
|
|
7a47994498 | ||
|
|
ece61915de | ||
|
|
1f66049a1e | ||
|
|
2fd657b768 | ||
|
|
8b5f2f9474 | ||
|
|
235b9b9269 | ||
|
|
470fef94fb | ||
|
|
82ef6bf96c | ||
|
|
b839a91050 | ||
|
|
d009c90e3a | ||
|
|
3768af4f92 | ||
|
|
d44a7ff8f9 | ||
|
|
559561ca6b | ||
|
|
713a305f45 | ||
|
|
ec5a04a6c7 | ||
|
|
a067d138e9 | ||
|
|
df1595e4bc | ||
|
|
ee6d432ced | ||
|
|
cf6eb138ce | ||
|
|
2bf73ccfe5 | ||
|
|
8c2baf0704 | ||
|
|
573c60ed6b | ||
|
|
7526ff9484 | ||
|
|
3634ad2d54 | ||
|
|
ecf9727568 |
12
.bunch
12
.bunch
@@ -1,7 +1,7 @@
|
||||
193
|
||||
201
|
||||
202_201
|
||||
192
|
||||
as36_192
|
||||
as40
|
||||
as41_201
|
||||
202
|
||||
193
|
||||
192_193
|
||||
as36_192_193
|
||||
as40_193
|
||||
as41
|
||||
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -3,5 +3,6 @@
|
||||
* text=auto
|
||||
* eol=lf
|
||||
*.png binary
|
||||
*.jar binary
|
||||
compiler/cli/bin/* eol=lf
|
||||
compiler/cli/bin/*.bat eol=crlf
|
||||
|
||||
15
.idea/codeStyles/Project.xml
generated
15
.idea/codeStyles/Project.xml
generated
@@ -13,21 +13,6 @@
|
||||
</option>
|
||||
</JavaCodeStyleSettings>
|
||||
<JetCodeStyleSettings>
|
||||
<option name="PACKAGES_TO_USE_STAR_IMPORTS">
|
||||
<value>
|
||||
<package name="java.util" alias="false" withSubpackages="false" />
|
||||
<package name="kotlinx.android.synthetic" alias="false" withSubpackages="true" />
|
||||
</value>
|
||||
</option>
|
||||
<option name="PACKAGES_IMPORT_LAYOUT">
|
||||
<value>
|
||||
<package name="" alias="false" withSubpackages="true" />
|
||||
<package name="java" alias="false" withSubpackages="true" />
|
||||
<package name="javax" alias="false" withSubpackages="true" />
|
||||
<package name="kotlin" alias="false" withSubpackages="true" />
|
||||
<package name="" alias="true" withSubpackages="true" />
|
||||
</value>
|
||||
</option>
|
||||
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
|
||||
</JetCodeStyleSettings>
|
||||
<MarkdownNavigatorCodeStyleSettings>
|
||||
|
||||
@@ -4,12 +4,13 @@
|
||||
<option name="executionName" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="externalSystemIdString" value="GRADLE" />
|
||||
<option name="scriptParameters" value="--tests "org.jetbrains.kotlin.js.test.ApiTest" -Poverwrite.output=true" />
|
||||
<option name="scriptParameters" value="--tests "org.jetbrains.kotlin.js.test.ApiTest" -Poverwrite.output=true --parallel" />
|
||||
<option name="taskDescriptions">
|
||||
<list />
|
||||
</option>
|
||||
<option name="taskNames">
|
||||
<list>
|
||||
<option value=":js:js.tests:cleanTest" />
|
||||
<option value=":js:js.tests:test" />
|
||||
</list>
|
||||
</option>
|
||||
|
||||
@@ -41,7 +41,12 @@ For local development, if you're not working on bytecode generation or the stand
|
||||
|
||||
You also can use [Gradle properties](https://docs.gradle.org/current/userguide/build_environment.html#sec:gradle_configuration_properties) to setup `JDK_*` variables.
|
||||
|
||||
> Note: The JDK 6 for MacOS is not available on Oracle's site. You can [download it here](https://support.apple.com/kb/DL1572).
|
||||
Note: The JDK 6 for MacOS is not available on Oracle's site. You can install it by
|
||||
|
||||
```bash
|
||||
$ brew tap caskroom/versions
|
||||
$ brew cask install java6
|
||||
```
|
||||
|
||||
On Windows you might need to add long paths setting to the repo:
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ package org.jetbrains.kotlin.incremental.storage
|
||||
|
||||
import com.intellij.util.io.DataExternalizer
|
||||
import com.intellij.util.io.KeyDescriptor
|
||||
import com.intellij.util.io.JpsPersistentHashMap
|
||||
import com.intellij.util.io.PersistentHashMap
|
||||
import java.io.File
|
||||
|
||||
|
||||
@@ -28,10 +28,10 @@ class NonCachingLazyStorage<K, V>(
|
||||
private val valueExternalizer: DataExternalizer<V>
|
||||
) : LazyStorage<K, V> {
|
||||
@Volatile
|
||||
private var storage: JpsPersistentHashMap<K, V>? = null
|
||||
private var storage: PersistentHashMap<K, V>? = null
|
||||
|
||||
@Synchronized
|
||||
private fun getStorageIfExists(): JpsPersistentHashMap<K, V>? {
|
||||
private fun getStorageIfExists(): PersistentHashMap<K, V>? {
|
||||
if (storage != null) return storage
|
||||
|
||||
if (storageFile.exists()) {
|
||||
@@ -43,7 +43,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
private fun getStorageOrCreateNew(): JpsPersistentHashMap<K, V> {
|
||||
private fun getStorageOrCreateNew(): PersistentHashMap<K, V> {
|
||||
if (storage == null) {
|
||||
storage = createMap()
|
||||
}
|
||||
@@ -69,7 +69,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
}
|
||||
|
||||
override fun append(key: K, value: V) {
|
||||
getStorageOrCreateNew().appendDataWithoutCache(key, value)
|
||||
getStorageOrCreateNew().appendData(key) { dataOutput -> valueExternalizer.save(dataOutput, value) }
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
@@ -79,7 +79,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
} catch (ignored: Throwable) {
|
||||
}
|
||||
|
||||
JpsPersistentHashMap.deleteFilesStartingWith(storageFile)
|
||||
PersistentHashMap.deleteFilesStartingWith(storageFile)
|
||||
storage = null
|
||||
}
|
||||
|
||||
@@ -101,6 +101,6 @@ class NonCachingLazyStorage<K, V>(
|
||||
storage?.close()
|
||||
}
|
||||
|
||||
private fun createMap(): JpsPersistentHashMap<K, V> =
|
||||
JpsPersistentHashMap(storageFile, keyDescriptor, valueExternalizer)
|
||||
private fun createMap(): PersistentHashMap<K, V> =
|
||||
PersistentHashMap(storageFile, keyDescriptor, valueExternalizer)
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ package org.jetbrains.kotlin.incremental.storage
|
||||
|
||||
import com.intellij.util.io.DataExternalizer
|
||||
import com.intellij.util.io.KeyDescriptor
|
||||
import com.intellij.util.io.PersistentHashMap
|
||||
import com.intellij.util.io.JpsPersistentHashMap
|
||||
import java.io.File
|
||||
|
||||
|
||||
@@ -28,10 +28,10 @@ class NonCachingLazyStorage<K, V>(
|
||||
private val valueExternalizer: DataExternalizer<V>
|
||||
) : LazyStorage<K, V> {
|
||||
@Volatile
|
||||
private var storage: PersistentHashMap<K, V>? = null
|
||||
private var storage: JpsPersistentHashMap<K, V>? = null
|
||||
|
||||
@Synchronized
|
||||
private fun getStorageIfExists(): PersistentHashMap<K, V>? {
|
||||
private fun getStorageIfExists(): JpsPersistentHashMap<K, V>? {
|
||||
if (storage != null) return storage
|
||||
|
||||
if (storageFile.exists()) {
|
||||
@@ -43,7 +43,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
private fun getStorageOrCreateNew(): PersistentHashMap<K, V> {
|
||||
private fun getStorageOrCreateNew(): JpsPersistentHashMap<K, V> {
|
||||
if (storage == null) {
|
||||
storage = createMap()
|
||||
}
|
||||
@@ -69,7 +69,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
}
|
||||
|
||||
override fun append(key: K, value: V) {
|
||||
getStorageOrCreateNew().appendData(key) { dataOutput -> valueExternalizer.save(dataOutput, value) }
|
||||
getStorageOrCreateNew().appendDataWithoutCache(key, value)
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
@@ -79,7 +79,7 @@ class NonCachingLazyStorage<K, V>(
|
||||
} catch (ignored: Throwable) {
|
||||
}
|
||||
|
||||
PersistentHashMap.deleteFilesStartingWith(storageFile)
|
||||
JpsPersistentHashMap.deleteFilesStartingWith(storageFile)
|
||||
storage = null
|
||||
}
|
||||
|
||||
@@ -101,6 +101,6 @@ class NonCachingLazyStorage<K, V>(
|
||||
storage?.close()
|
||||
}
|
||||
|
||||
private fun createMap(): PersistentHashMap<K, V> =
|
||||
PersistentHashMap(storageFile, keyDescriptor, valueExternalizer)
|
||||
private fun createMap(): JpsPersistentHashMap<K, V> =
|
||||
JpsPersistentHashMap(storageFile, keyDescriptor, valueExternalizer)
|
||||
}
|
||||
@@ -235,6 +235,7 @@ extra["compilerModules"] = arrayOf(
|
||||
":compiler:ir.serialization.common",
|
||||
":compiler:ir.serialization.js",
|
||||
":compiler:ir.serialization.jvm",
|
||||
":compiler:ir.interpreter",
|
||||
":kotlin-util-io",
|
||||
":kotlin-util-klib",
|
||||
":kotlin-util-klib-metadata",
|
||||
@@ -307,7 +308,6 @@ val coreLibProjects = listOfNotNull(
|
||||
":kotlin-stdlib",
|
||||
":kotlin-stdlib-common",
|
||||
":kotlin-stdlib-js",
|
||||
":kotlin-stdlib-js-ir",
|
||||
":kotlin-stdlib-jdk7",
|
||||
":kotlin-stdlib-jdk8",
|
||||
":kotlin-test:kotlin-test-annotations-common",
|
||||
@@ -317,7 +317,6 @@ val coreLibProjects = listOfNotNull(
|
||||
":kotlin-test:kotlin-test-junit5",
|
||||
":kotlin-test:kotlin-test-testng",
|
||||
":kotlin-test:kotlin-test-js".takeIf { !kotlinBuildProperties.isInJpsBuildIdeaSync },
|
||||
":kotlin-test:kotlin-test-js-ir".takeIf { !kotlinBuildProperties.isInJpsBuildIdeaSync },
|
||||
":kotlin-reflect",
|
||||
":kotlin-coroutines-experimental-compat"
|
||||
)
|
||||
@@ -366,6 +365,15 @@ allprojects {
|
||||
}
|
||||
}
|
||||
|
||||
configurations.maybeCreate("embeddedElements").apply {
|
||||
extendsFrom(configurations["embedded"])
|
||||
isCanBeConsumed = true
|
||||
isCanBeResolved = false
|
||||
attributes {
|
||||
attribute(Usage.USAGE_ATTRIBUTE, objects.named("embedded-java-runtime"))
|
||||
}
|
||||
}
|
||||
|
||||
jvmTarget = defaultJvmTarget
|
||||
javaHome = defaultJavaHome
|
||||
|
||||
@@ -514,6 +522,10 @@ val dist = tasks.register("dist") {
|
||||
dependsOn(":kotlin-compiler:dist")
|
||||
}
|
||||
|
||||
val syncMutedTests = tasks.register("syncMutedTests") {
|
||||
dependsOn(":compiler:tests-mutes:run")
|
||||
}
|
||||
|
||||
val copyCompilerToIdeaPlugin by task<Copy> {
|
||||
dependsOn(dist)
|
||||
into(ideaPluginDir)
|
||||
@@ -539,7 +551,7 @@ tasks {
|
||||
}
|
||||
}
|
||||
|
||||
listOf("clean", "assemble", "install", "dist").forEach { taskName ->
|
||||
listOf("clean", "assemble", "install").forEach { taskName ->
|
||||
register("coreLibs${taskName.capitalize()}") {
|
||||
coreLibProjects.forEach { projectName -> dependsOn("$projectName:$taskName") }
|
||||
}
|
||||
@@ -548,6 +560,8 @@ tasks {
|
||||
register("coreLibsTest") {
|
||||
(coreLibProjects + listOf(
|
||||
":kotlin-stdlib:samples",
|
||||
":kotlin-stdlib-js-ir",
|
||||
":kotlin-test:kotlin-test-js-ir".takeIf { !kotlinBuildProperties.isInJpsBuildIdeaSync },
|
||||
":kotlin-test:kotlin-test-js:kotlin-test-js-it".takeIf { !kotlinBuildProperties.isInJpsBuildIdeaSync },
|
||||
":kotlinx-metadata-jvm",
|
||||
":tools:binary-compatibility-validator"
|
||||
@@ -804,7 +818,9 @@ tasks {
|
||||
":kotlin-stdlib-jdk7:publish",
|
||||
":kotlin-stdlib-jdk8:publish",
|
||||
":kotlin-reflect:publish",
|
||||
":kotlin-main-kts:publish"
|
||||
":kotlin-main-kts:publish",
|
||||
":kotlin-stdlib-js:publish",
|
||||
":kotlin-test:kotlin-test-js:publish"
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -96,6 +96,7 @@ repositories {
|
||||
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib", embeddedKotlinVersion))
|
||||
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:${project.bootstrapKotlinVersion}")
|
||||
implementation("org.jetbrains.kotlin:kotlin-build-gradle-plugin:0.0.17")
|
||||
implementation("com.gradle.publish:plugin-publish-plugin:0.11.0")
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@ import org.gradle.api.tasks.javadoc.Javadoc
|
||||
import org.gradle.jvm.tasks.Jar
|
||||
import org.gradle.api.artifacts.dsl.DependencyHandler
|
||||
import org.gradle.kotlin.dsl.*
|
||||
import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetContainer
|
||||
import plugins.KotlinBuildPublishingPlugin
|
||||
|
||||
|
||||
@@ -129,10 +130,16 @@ fun Project.sourcesJar(body: Jar.() -> Unit = {}): TaskProvider<Jar> {
|
||||
}
|
||||
|
||||
val sourcesJar = getOrCreateTask<Jar>("sourcesJar") {
|
||||
fun Project.mainJavaPluginSourceSet() = findJavaPluginConvention()?.sourceSets?.findByName("main")
|
||||
fun Project.mainKotlinSourceSet() =
|
||||
(extensions.findByName("kotlin") as? KotlinSourceSetContainer)?.sourceSets?.findByName("main")
|
||||
|
||||
fun Project.sources() = mainJavaPluginSourceSet()?.allSource ?: mainKotlinSourceSet()?.kotlin
|
||||
|
||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||
archiveClassifier.set("sources")
|
||||
|
||||
from(project.mainSourceSet.allSource)
|
||||
from(project.sources())
|
||||
|
||||
project.configurations.findByName("embedded")?.let { embedded ->
|
||||
from(provider {
|
||||
@@ -141,10 +148,7 @@ fun Project.sourcesJar(body: Jar.() -> Unit = {}): TaskProvider<Jar> {
|
||||
.map { it.id.componentIdentifier }
|
||||
.filterIsInstance<ProjectComponentIdentifier>()
|
||||
.mapNotNull {
|
||||
project(it.projectPath)
|
||||
.findJavaPluginConvention()
|
||||
?.mainSourceSet
|
||||
?.allSource
|
||||
project(it.projectPath).sources()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -9,12 +9,16 @@ import org.gradle.api.Project
|
||||
import org.gradle.api.publish.PublicationContainer
|
||||
import org.gradle.api.publish.PublishingExtension
|
||||
import org.gradle.api.publish.maven.MavenPublication
|
||||
import org.gradle.api.publish.maven.tasks.PublishToMavenRepository
|
||||
import org.gradle.api.tasks.bundling.Jar
|
||||
import org.gradle.kotlin.dsl.*
|
||||
import plugins.KotlinBuildPublishingPlugin
|
||||
import plugins.configureRepository
|
||||
import java.util.*
|
||||
|
||||
internal const val PLUGIN_MARKER_SUFFIX = ".gradle.plugin"
|
||||
|
||||
@UseExperimental(ExperimentalStdlibApi::class)
|
||||
fun Project.publishPluginMarkers(withEmptyJars: Boolean = true) {
|
||||
val pluginDevelopment = extensions.getByType<PluginBundleExtension>()
|
||||
val publishingExtension = extensions.getByType<PublishingExtension>()
|
||||
@@ -25,6 +29,10 @@ fun Project.publishPluginMarkers(withEmptyJars: Boolean = true) {
|
||||
if (withEmptyJars) {
|
||||
addEmptyJarArtifacts(markerPublication)
|
||||
}
|
||||
|
||||
tasks.named<PublishToMavenRepository>(
|
||||
"publish${markerPublication.name.capitalize(Locale.ROOT)}PublicationTo${KotlinBuildPublishingPlugin.REPOSITORY_NAME}Repository"
|
||||
).configureRepository()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -15,9 +15,11 @@ import org.gradle.api.publish.PublishingExtension
|
||||
import org.gradle.api.publish.maven.MavenPublication
|
||||
import org.gradle.api.publish.maven.plugins.MavenPublishPlugin
|
||||
import org.gradle.api.publish.maven.tasks.PublishToMavenRepository
|
||||
import org.gradle.api.tasks.TaskProvider
|
||||
import org.gradle.kotlin.dsl.*
|
||||
import org.gradle.plugins.signing.SigningExtension
|
||||
import org.gradle.plugins.signing.SigningPlugin
|
||||
import java.net.URI
|
||||
import java.util.*
|
||||
import javax.inject.Inject
|
||||
|
||||
@@ -119,25 +121,8 @@ class KotlinBuildPublishingPlugin @Inject constructor(
|
||||
dependsOn(tasks.named("publishToMavenLocal"))
|
||||
}
|
||||
|
||||
tasks.named<PublishToMavenRepository>("publish${PUBLICATION_NAME}PublicationTo${REPOSITORY_NAME}Repository") {
|
||||
dependsOn(project.rootProject.tasks.named("preparePublication"))
|
||||
doFirst {
|
||||
val preparePublication = project.rootProject.tasks.named("preparePublication").get()
|
||||
val username: String? by preparePublication.extra
|
||||
val password: String? by preparePublication.extra
|
||||
val repoUrl: String by preparePublication.extra
|
||||
|
||||
repository.apply {
|
||||
url = uri(repoUrl)
|
||||
if (url.scheme != "file" && username != null && password != null) {
|
||||
credentials {
|
||||
this.username = username
|
||||
this.password = password
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
tasks.named<PublishToMavenRepository>("publish${PUBLICATION_NAME}PublicationTo${REPOSITORY_NAME}Repository")
|
||||
.configureRepository()
|
||||
}
|
||||
|
||||
companion object {
|
||||
@@ -152,4 +137,24 @@ class KotlinBuildPublishingPlugin @Inject constructor(
|
||||
fun humanReadableName(project: Project) =
|
||||
project.name.split("-").joinToString(separator = " ") { it.capitalize(Locale.ROOT) }
|
||||
}
|
||||
}
|
||||
|
||||
fun TaskProvider<PublishToMavenRepository>.configureRepository() = configure {
|
||||
dependsOn(project.rootProject.tasks.named("preparePublication"))
|
||||
doFirst {
|
||||
val preparePublication = project.rootProject.tasks.named("preparePublication").get()
|
||||
val username: String? by preparePublication.extra
|
||||
val password: String? by preparePublication.extra
|
||||
val repoUrl: String by preparePublication.extra
|
||||
|
||||
repository.apply {
|
||||
url = project.uri(repoUrl)
|
||||
if (url.scheme != "file" && username != null && password != null) {
|
||||
credentials {
|
||||
this.username = username
|
||||
this.password = password
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -294,7 +294,7 @@ class CodegenTestsOnAndroidGenerator private constructor(private val pathManager
|
||||
val kind = KotlinBaseTest.extractConfigurationKind(testFiles)
|
||||
val jdkKind = KotlinBaseTest.getTestJdkKind(testFiles)
|
||||
val keyConfiguration = CompilerConfiguration()
|
||||
CodegenTestCase.updateConfigurationByDirectivesInTestFiles(testFiles, keyConfiguration)
|
||||
KotlinBaseTest.updateConfigurationByDirectivesInTestFiles(testFiles, keyConfiguration)
|
||||
|
||||
val key = ConfigurationKey(kind, jdkKind, keyConfiguration.toString())
|
||||
val compiler = if (isJvm8Target) {
|
||||
@@ -303,7 +303,7 @@ class CodegenTestsOnAndroidGenerator private constructor(private val pathManager
|
||||
val filesHolder = holders.getOrPut(key) {
|
||||
FilesWriter(compiler, KotlinTestUtils.newConfiguration(kind, jdkKind, KotlinTestUtils.getAnnotationsJar()).apply {
|
||||
println("Creating new configuration by $key")
|
||||
CodegenTestCase.updateConfigurationByDirectivesInTestFiles(testFiles, this)
|
||||
KotlinBaseTest.updateConfigurationByDirectivesInTestFiles(testFiles, this)
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -8,7 +8,6 @@ package org.jetbrains.kotlin.backend.common
|
||||
import com.intellij.openapi.application.ApplicationManager
|
||||
import com.intellij.openapi.project.Project
|
||||
import com.intellij.psi.PsiElement
|
||||
import org.jetbrains.kotlin.backend.common.bridges.findInterfaceImplementation
|
||||
import org.jetbrains.kotlin.descriptors.*
|
||||
import org.jetbrains.kotlin.diagnostics.DiagnosticSink
|
||||
import org.jetbrains.kotlin.diagnostics.Errors
|
||||
@@ -24,6 +23,7 @@ import org.jetbrains.kotlin.resolve.calls.callUtil.getResolvedCall
|
||||
import org.jetbrains.kotlin.resolve.multiplatform.ExpectedActualResolver
|
||||
import org.jetbrains.kotlin.types.KotlinType
|
||||
import org.jetbrains.kotlin.util.getExceptionMessage
|
||||
import org.jetbrains.kotlin.util.getNonPrivateTraitMembersForDelegation
|
||||
import org.jetbrains.kotlin.utils.DFS
|
||||
import org.jetbrains.kotlin.utils.KotlinExceptionWithAttachments
|
||||
|
||||
@@ -55,14 +55,8 @@ object CodegenUtil {
|
||||
@JvmOverloads
|
||||
fun getNonPrivateTraitMethods(descriptor: ClassDescriptor, copy: Boolean = true): Map<FunctionDescriptor, FunctionDescriptor> {
|
||||
val result = linkedMapOf<FunctionDescriptor, FunctionDescriptor>()
|
||||
for (declaration in DescriptorUtils.getAllDescriptors(descriptor.defaultType.memberScope)) {
|
||||
if (declaration !is CallableMemberDescriptor) continue
|
||||
|
||||
val traitMember = findInterfaceImplementation(declaration)
|
||||
if (traitMember == null ||
|
||||
Visibilities.isPrivate(traitMember.visibility) ||
|
||||
traitMember.visibility == Visibilities.INVISIBLE_FAKE) continue
|
||||
|
||||
for ((declaration, traitMember) in getNonPrivateTraitMembersForDelegation(descriptor)) {
|
||||
assert(traitMember.modality !== Modality.ABSTRACT) { "Cannot delegate to abstract trait method: $declaration" }
|
||||
|
||||
// inheritedMember can be abstract here. In order for FunctionCodegen to generate the method body, we're creating a copy here
|
||||
|
||||
@@ -24,6 +24,8 @@ import org.jetbrains.kotlin.resolve.OverridingUtil
|
||||
import org.jetbrains.kotlin.resolve.calls.callResolverUtil.isOrOverridesSynthesized
|
||||
import org.jetbrains.kotlin.resolve.descriptorUtil.isTypeRefinementEnabled
|
||||
import org.jetbrains.kotlin.resolve.descriptorUtil.module
|
||||
import org.jetbrains.kotlin.util.findImplementationFromInterface
|
||||
import org.jetbrains.kotlin.util.findInterfaceImplementation
|
||||
|
||||
fun <Signature> generateBridgesForFunctionDescriptor(
|
||||
descriptor: FunctionDescriptor,
|
||||
@@ -81,60 +83,4 @@ open class DescriptorBasedFunctionHandle(val descriptor: FunctionDescriptor) : F
|
||||
override fun toString(): String {
|
||||
return descriptor.toString()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Given a fake override in a class, returns an overridden declaration with implementation in trait, such that a method delegating to that
|
||||
* trait implementation should be generated into the class containing the fake override; or null if the given function is not a fake
|
||||
* override of any trait implementation or such method was already generated into the superclass or is a method from Any.
|
||||
*/
|
||||
fun findInterfaceImplementation(descriptor: CallableMemberDescriptor): CallableMemberDescriptor? {
|
||||
if (descriptor.kind.isReal) return null
|
||||
if (isOrOverridesSynthesized(descriptor)) return null
|
||||
|
||||
val implementation = findImplementationFromInterface(descriptor) ?: return null
|
||||
val immediateConcreteSuper = firstSuperMethodFromKotlin(descriptor, implementation) ?: return null
|
||||
|
||||
if (!DescriptorUtils.isInterface(immediateConcreteSuper.containingDeclaration)) {
|
||||
// If this implementation is already generated into the superclass, we need not generate it again, it'll be inherited
|
||||
return null
|
||||
}
|
||||
|
||||
return immediateConcreteSuper
|
||||
}
|
||||
|
||||
/**
|
||||
* Given a fake override, returns an overridden non-abstract function from an interface which is the actual implementation of this function
|
||||
* that should be called when the given fake override is called.
|
||||
*/
|
||||
fun findImplementationFromInterface(descriptor: CallableMemberDescriptor): CallableMemberDescriptor? {
|
||||
val overridden = OverridingUtil.getOverriddenDeclarations(descriptor)
|
||||
val filtered = OverridingUtil.filterOutOverridden(overridden)
|
||||
|
||||
val result = filtered.firstOrNull { it.modality != Modality.ABSTRACT } ?: return null
|
||||
|
||||
if (DescriptorUtils.isClassOrEnumClass(result.containingDeclaration)) return null
|
||||
|
||||
return result
|
||||
}
|
||||
|
||||
/**
|
||||
* Given a fake override and its implementation (non-abstract declaration) somewhere in supertypes,
|
||||
* returns the first immediate super function of the given fake override which overrides that implementation.
|
||||
* The returned function should be called from TImpl-bridges generated for the given fake override.
|
||||
*/
|
||||
fun firstSuperMethodFromKotlin(
|
||||
descriptor: CallableMemberDescriptor,
|
||||
implementation: CallableMemberDescriptor
|
||||
): CallableMemberDescriptor? {
|
||||
return descriptor.overriddenDescriptors.firstOrNull { overridden ->
|
||||
overridden.modality != Modality.ABSTRACT &&
|
||||
(overridden == implementation || OverridingUtil.overrides(
|
||||
overridden,
|
||||
implementation,
|
||||
overridden.module.isTypeRefinementEnabled(),
|
||||
true
|
||||
))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -90,12 +90,18 @@ public abstract class AnnotationCodegen {
|
||||
private final KotlinTypeMapper typeMapper;
|
||||
private final ModuleDescriptor module;
|
||||
private final GenerationState state;
|
||||
private final boolean skipNullabilityAnnotations;
|
||||
|
||||
private AnnotationCodegen(@NotNull InnerClassConsumer innerClassConsumer, @NotNull GenerationState state) {
|
||||
this(innerClassConsumer, state, false);
|
||||
}
|
||||
|
||||
private AnnotationCodegen(@NotNull InnerClassConsumer innerClassConsumer, @NotNull GenerationState state, boolean skipNullabilityAnnotations) {
|
||||
this.innerClassConsumer = innerClassConsumer;
|
||||
this.typeMapper = state.getTypeMapper();
|
||||
this.module = state.getModule();
|
||||
this.state = state;
|
||||
this.skipNullabilityAnnotations = skipNullabilityAnnotations;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -105,6 +111,16 @@ public abstract class AnnotationCodegen {
|
||||
@Nullable Annotated annotated,
|
||||
@Nullable Type returnType,
|
||||
@Nullable KotlinType typeForTypeAnnotations
|
||||
) {
|
||||
genAnnotations(annotated, returnType, typeForTypeAnnotations, null, Collections.emptyList());
|
||||
}
|
||||
|
||||
public void genAnnotations(
|
||||
@Nullable Annotated annotated,
|
||||
@Nullable Type returnType,
|
||||
@Nullable KotlinType typeForTypeAnnotations,
|
||||
@Nullable DeclarationDescriptorWithVisibility parameterContainer,
|
||||
@NotNull List<Class<?>> additionalAnnotations
|
||||
) {
|
||||
if (annotated == null) return;
|
||||
|
||||
@@ -139,22 +155,28 @@ public abstract class AnnotationCodegen {
|
||||
}
|
||||
}
|
||||
|
||||
generateAdditionalAnnotations(annotated, returnType, annotationDescriptorsAlreadyPresent);
|
||||
for (Class<?> annotation : additionalAnnotations) {
|
||||
String descriptor = generateAnnotationIfNotPresent(annotationDescriptorsAlreadyPresent, annotation);
|
||||
annotationDescriptorsAlreadyPresent.add(descriptor);
|
||||
}
|
||||
|
||||
generateAdditionalAnnotations(annotated, returnType, annotationDescriptorsAlreadyPresent, parameterContainer);
|
||||
generateTypeAnnotations(annotated, typeForTypeAnnotations);
|
||||
}
|
||||
|
||||
private void generateAdditionalAnnotations(
|
||||
@NotNull Annotated annotated,
|
||||
@Nullable Type returnType,
|
||||
@NotNull Set<String> annotationDescriptorsAlreadyPresent
|
||||
@NotNull Set<String> annotationDescriptorsAlreadyPresent,
|
||||
@Nullable DeclarationDescriptorWithVisibility parameterContainer
|
||||
) {
|
||||
if (annotated instanceof CallableDescriptor) {
|
||||
generateAdditionalCallableAnnotations((CallableDescriptor) annotated, returnType, annotationDescriptorsAlreadyPresent);
|
||||
generateAdditionalCallableAnnotations((CallableDescriptor) annotated, returnType, annotationDescriptorsAlreadyPresent, parameterContainer);
|
||||
}
|
||||
else if (annotated instanceof FieldDescriptor) {
|
||||
generateAdditionalCallableAnnotations(
|
||||
((FieldDescriptor) annotated).getCorrespondingProperty(), returnType, annotationDescriptorsAlreadyPresent
|
||||
);
|
||||
((FieldDescriptor) annotated).getCorrespondingProperty(), returnType, annotationDescriptorsAlreadyPresent,
|
||||
parameterContainer);
|
||||
}
|
||||
else if (annotated instanceof ClassDescriptor) {
|
||||
generateAdditionalClassAnnotations(annotationDescriptorsAlreadyPresent, (ClassDescriptor) annotated);
|
||||
@@ -164,11 +186,15 @@ public abstract class AnnotationCodegen {
|
||||
private void generateAdditionalCallableAnnotations(
|
||||
@NotNull CallableDescriptor descriptor,
|
||||
@Nullable Type returnType,
|
||||
@NotNull Set<String> annotationDescriptorsAlreadyPresent
|
||||
@NotNull Set<String> annotationDescriptorsAlreadyPresent,
|
||||
@Nullable DeclarationDescriptorWithVisibility parameterContainer
|
||||
) {
|
||||
// No need to annotate privates, synthetic accessors and their parameters
|
||||
if (isInvisibleFromTheOutside(descriptor)) return;
|
||||
if (descriptor instanceof ValueParameterDescriptor && isInvisibleFromTheOutside(descriptor.getContainingDeclaration())) return;
|
||||
if (descriptor instanceof ParameterDescriptor &&
|
||||
isInvisibleFromTheOutside(parameterContainer != null ? parameterContainer : descriptor.getContainingDeclaration())) {
|
||||
return;
|
||||
}
|
||||
|
||||
// No need to annotate annotation methods since they're always non-null
|
||||
if (descriptor instanceof PropertyGetterDescriptor &&
|
||||
@@ -176,7 +202,7 @@ public abstract class AnnotationCodegen {
|
||||
return;
|
||||
}
|
||||
|
||||
if (returnType != null && !AsmUtil.isPrimitive(returnType)) {
|
||||
if (returnType != null && !AsmUtil.isPrimitive(returnType) && !skipNullabilityAnnotations) {
|
||||
generateNullabilityAnnotation(descriptor.getReturnType(), annotationDescriptorsAlreadyPresent);
|
||||
}
|
||||
}
|
||||
@@ -312,11 +338,13 @@ public abstract class AnnotationCodegen {
|
||||
visitor.visitEnd();
|
||||
}
|
||||
|
||||
private void generateAnnotationIfNotPresent(Set<String> annotationDescriptorsAlreadyPresent, Class<?> annotationClass) {
|
||||
@NotNull
|
||||
private String generateAnnotationIfNotPresent(Set<String> annotationDescriptorsAlreadyPresent, Class<?> annotationClass) {
|
||||
String descriptor = Type.getType(annotationClass).getDescriptor();
|
||||
if (!annotationDescriptorsAlreadyPresent.contains(descriptor)) {
|
||||
visitAnnotation(descriptor, false).visitEnd();
|
||||
}
|
||||
return descriptor;
|
||||
}
|
||||
|
||||
private static boolean isBareTypeParameterWithNullableUpperBound(@NotNull KotlinType type) {
|
||||
@@ -600,7 +628,16 @@ public abstract class AnnotationCodegen {
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state
|
||||
) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state) {
|
||||
return forMethod(mv, innerClassConsumer, state, false);
|
||||
}
|
||||
|
||||
public static AnnotationCodegen forMethod(
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state,
|
||||
boolean skipNullabilityAnnotations
|
||||
) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state, skipNullabilityAnnotations) {
|
||||
@NotNull
|
||||
@Override
|
||||
AnnotationVisitor visitAnnotation(String descr, boolean visible) {
|
||||
@@ -620,7 +657,16 @@ public abstract class AnnotationCodegen {
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state
|
||||
) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state) {
|
||||
return forField(fv, innerClassConsumer, state, false);
|
||||
}
|
||||
|
||||
public static AnnotationCodegen forField(
|
||||
@NotNull FieldVisitor fv,
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state,
|
||||
boolean skipNullabilityAnnotations
|
||||
) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state, skipNullabilityAnnotations) {
|
||||
@NotNull
|
||||
@Override
|
||||
AnnotationVisitor visitAnnotation(String descr, boolean visible) {
|
||||
@@ -639,9 +685,10 @@ public abstract class AnnotationCodegen {
|
||||
int parameter,
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state
|
||||
@NotNull GenerationState state,
|
||||
boolean skipNullabilityAnnotations
|
||||
) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state) {
|
||||
return new AnnotationCodegen(innerClassConsumer, state, skipNullabilityAnnotations) {
|
||||
@NotNull
|
||||
@Override
|
||||
AnnotationVisitor visitAnnotation(String descr, boolean visible) {
|
||||
|
||||
@@ -10,7 +10,6 @@ import kotlin.collections.CollectionsKt;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.backend.common.CodegenUtil;
|
||||
import org.jetbrains.kotlin.backend.common.bridges.ImplKt;
|
||||
import org.jetbrains.kotlin.builtins.KotlinBuiltIns;
|
||||
import org.jetbrains.kotlin.codegen.context.ClassContext;
|
||||
import org.jetbrains.kotlin.codegen.state.GenerationState;
|
||||
@@ -39,6 +38,7 @@ import static org.jetbrains.kotlin.codegen.binding.CodegenBinding.enumEntryNeedS
|
||||
import static org.jetbrains.kotlin.resolve.DescriptorToSourceUtils.descriptorToDeclaration;
|
||||
import static org.jetbrains.kotlin.resolve.jvm.AsmTypes.OBJECT_TYPE;
|
||||
import static org.jetbrains.kotlin.resolve.jvm.diagnostics.JvmDeclarationOriginKind.CLASS_MEMBER_DELEGATION_TO_DEFAULT_IMPL;
|
||||
import static org.jetbrains.kotlin.util.DeclarationUtilKt.findInterfaceImplementation;
|
||||
|
||||
public abstract class ClassBodyCodegen extends MemberCodegen<KtPureClassOrObject> {
|
||||
@NotNull
|
||||
@@ -125,7 +125,7 @@ public abstract class ClassBodyCodegen extends MemberCodegen<KtPureClassOrObject
|
||||
for (DeclarationDescriptor memberDescriptor : DescriptorUtils.getAllDescriptors(descriptor.getDefaultType().getMemberScope())) {
|
||||
if (memberDescriptor instanceof CallableMemberDescriptor) {
|
||||
CallableMemberDescriptor member = (CallableMemberDescriptor) memberDescriptor;
|
||||
if (!member.getKind().isReal() && ImplKt.findInterfaceImplementation(member) == null) {
|
||||
if (!member.getKind().isReal() && findInterfaceImplementation(member) == null) {
|
||||
if (member instanceof FunctionDescriptor) {
|
||||
functionCodegen.generateBridges((FunctionDescriptor) member);
|
||||
}
|
||||
@@ -238,10 +238,7 @@ public abstract class ClassBodyCodegen extends MemberCodegen<KtPureClassOrObject
|
||||
) {
|
||||
// Skip Java 8 default methods
|
||||
if (CodegenUtilKt.isDefinitelyNotDefaultImplsMethod(interfaceFun) ||
|
||||
JvmAnnotationUtilKt.isCallableMemberCompiledToJvmDefault(
|
||||
DescriptorUtils.unwrapFakeOverrideToAnyDeclaration(interfaceFun), state.getJvmDefaultMode()
|
||||
)
|
||||
) {
|
||||
JvmAnnotationUtilKt.checkIsImplementationCompiledToJvmDefault(interfaceFun, state.getJvmDefaultMode())) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -153,18 +153,18 @@ class DefaultParameterValueSubstitutor(val state: GenerationState) {
|
||||
signature.genericsSignature,
|
||||
FunctionCodegen.getThrownExceptions(functionDescriptor, typeMapper)
|
||||
)
|
||||
val skipNullabilityAnnotations = flags and Opcodes.ACC_PRIVATE != 0 || flags and Opcodes.ACC_SYNTHETIC != 0
|
||||
|
||||
AnnotationCodegen.forMethod(mv, memberCodegen, state).genAnnotations(
|
||||
functionDescriptor,
|
||||
signature.returnType,
|
||||
functionDescriptor.returnType
|
||||
)
|
||||
AnnotationCodegen.forMethod(mv, memberCodegen, state, skipNullabilityAnnotations)
|
||||
.genAnnotations(functionDescriptor, signature.returnType, functionDescriptor.returnType)
|
||||
|
||||
if (state.classBuilderMode == ClassBuilderMode.KAPT3) {
|
||||
mv.visitAnnotation(ANNOTATION_TYPE_DESCRIPTOR_FOR_JVM_OVERLOADS_GENERATED_METHODS, false)
|
||||
}
|
||||
|
||||
FunctionCodegen.generateParameterAnnotations(functionDescriptor, mv, signature, remainingParameters, memberCodegen, state)
|
||||
FunctionCodegen.generateParameterAnnotations(
|
||||
functionDescriptor, mv, signature, remainingParameters, memberCodegen, state, skipNullabilityAnnotations
|
||||
)
|
||||
|
||||
if (!state.classBuilderMode.generateBodies) {
|
||||
FunctionCodegen.generateLocalVariablesForParameters(
|
||||
|
||||
@@ -193,6 +193,10 @@ public class FunctionCodegen {
|
||||
if (origin.getOriginKind() == JvmDeclarationOriginKind.SAM_DELEGATION) {
|
||||
flags |= ACC_SYNTHETIC;
|
||||
}
|
||||
boolean isCompatibilityStubInDefaultImpls = isCompatibilityStubInDefaultImpls(functionDescriptor, methodContext, state.getJvmDefaultMode());
|
||||
if (isCompatibilityStubInDefaultImpls) {
|
||||
flags |= ACC_DEPRECATED;
|
||||
}
|
||||
|
||||
if (functionDescriptor.isExternal() && owner instanceof MultifileClassFacadeContext) {
|
||||
// Native methods are only defined in facades and do not need package part implementations
|
||||
@@ -201,12 +205,13 @@ public class FunctionCodegen {
|
||||
|
||||
MethodVisitor mv =
|
||||
strategy.wrapMethodVisitor(
|
||||
newMethod(origin,
|
||||
flags,
|
||||
asmMethod.getName(),
|
||||
asmMethod.getDescriptor(),
|
||||
strategy.skipGenericSignature() ? null : jvmSignature.getGenericsSignature(),
|
||||
getThrownExceptions(functionDescriptor, typeMapper)
|
||||
newMethod(
|
||||
origin,
|
||||
flags,
|
||||
asmMethod.getName(),
|
||||
asmMethod.getDescriptor(),
|
||||
strategy.skipGenericSignature() ? null : jvmSignature.getGenericsSignature(),
|
||||
getThrownExceptions(functionDescriptor, typeMapper)
|
||||
),
|
||||
flags, asmMethod.getName(),
|
||||
asmMethod.getDescriptor()
|
||||
@@ -214,8 +219,12 @@ public class FunctionCodegen {
|
||||
|
||||
recordMethodForFunctionIfAppropriate(functionDescriptor, asmMethod);
|
||||
|
||||
generateMethodAnnotationsIfRequired(functionDescriptor, asmMethod, jvmSignature, mv);
|
||||
|
||||
boolean skipNullabilityAnnotations = (flags & ACC_PRIVATE) != 0 || (flags & ACC_SYNTHETIC) != 0;
|
||||
generateMethodAnnotationsIfRequired(
|
||||
functionDescriptor, asmMethod, jvmSignature, mv,
|
||||
isCompatibilityStubInDefaultImpls ? Collections.singletonList(Deprecated.class) : Collections.emptyList(),
|
||||
skipNullabilityAnnotations
|
||||
);
|
||||
GenerateJava8ParameterNamesKt.generateParameterNames(functionDescriptor, mv, jvmSignature, state, (flags & ACC_SYNTHETIC) != 0);
|
||||
|
||||
if (contextKind != OwnerKind.ERASED_INLINE_CLASS) {
|
||||
@@ -276,7 +285,9 @@ public class FunctionCodegen {
|
||||
@NotNull FunctionDescriptor functionDescriptor,
|
||||
@NotNull Method asmMethod,
|
||||
@NotNull JvmMethodGenericSignature jvmSignature,
|
||||
@NotNull MethodVisitor mv
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull List<Class<?>> additionalNoArgAnnotations,
|
||||
boolean skipNullabilityAnnotations
|
||||
) {
|
||||
FunctionDescriptor annotationsOwner;
|
||||
if (shouldHideConstructorDueToInlineClassTypeValueParameters(functionDescriptor)) {
|
||||
@@ -291,10 +302,14 @@ public class FunctionCodegen {
|
||||
annotationsOwner = functionDescriptor;
|
||||
}
|
||||
|
||||
AnnotationCodegen.forMethod(mv, memberCodegen, state)
|
||||
.genAnnotations(annotationsOwner, asmMethod.getReturnType(), functionDescriptor.getReturnType());
|
||||
AnnotationCodegen.forMethod(mv, memberCodegen, state, skipNullabilityAnnotations)
|
||||
.genAnnotations(annotationsOwner, asmMethod.getReturnType(), functionDescriptor.getReturnType(), null, additionalNoArgAnnotations);
|
||||
|
||||
generateParameterAnnotations(annotationsOwner, mv, jvmSignature, memberCodegen, state);
|
||||
generateParameterAnnotations(
|
||||
annotationsOwner, mv, jvmSignature,
|
||||
annotationsOwner.getValueParameters(),
|
||||
memberCodegen, state, skipNullabilityAnnotations
|
||||
);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@@ -488,25 +503,14 @@ public class FunctionCodegen {
|
||||
return descriptor != null && !InlineUtil.isInlineOrContainingInline(descriptor);
|
||||
}
|
||||
|
||||
public static void generateParameterAnnotations(
|
||||
@NotNull FunctionDescriptor functionDescriptor,
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull JvmMethodSignature jvmSignature,
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state
|
||||
) {
|
||||
generateParameterAnnotations(
|
||||
functionDescriptor, mv, jvmSignature, functionDescriptor.getValueParameters(), innerClassConsumer, state
|
||||
);
|
||||
}
|
||||
|
||||
public static void generateParameterAnnotations(
|
||||
@NotNull FunctionDescriptor functionDescriptor,
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull JvmMethodSignature jvmSignature,
|
||||
@NotNull List<ValueParameterDescriptor> valueParameters,
|
||||
@NotNull InnerClassConsumer innerClassConsumer,
|
||||
@NotNull GenerationState state
|
||||
@NotNull MemberCodegen<?> memberCodegen,
|
||||
@NotNull GenerationState state,
|
||||
boolean skipNullabilityAnnotations
|
||||
) {
|
||||
if (isAccessor(functionDescriptor)) return;
|
||||
|
||||
@@ -516,6 +520,7 @@ public class FunctionCodegen {
|
||||
|
||||
Asm7UtilKt.visitAnnotableParameterCount(mv, kotlinParameterTypes.size() - syntheticParameterCount);
|
||||
|
||||
boolean isDefaultImpl = OwnerKind.DEFAULT_IMPLS == memberCodegen.context.getContextKind();
|
||||
for (int i = 0; i < kotlinParameterTypes.size(); i++) {
|
||||
JvmMethodParameterSignature parameterSignature = kotlinParameterTypes.get(i);
|
||||
JvmMethodParameterKind kind = parameterSignature.getKind();
|
||||
@@ -528,13 +533,14 @@ public class FunctionCodegen {
|
||||
? iterator.next()
|
||||
: kind == JvmMethodParameterKind.RECEIVER
|
||||
? JvmCodegenUtil.getDirectMember(functionDescriptor).getExtensionReceiverParameter()
|
||||
: null;
|
||||
: isDefaultImpl && kind == JvmMethodParameterKind.THIS ? JvmCodegenUtil.getDirectMember(functionDescriptor)
|
||||
.getDispatchReceiverParameter() : null;
|
||||
|
||||
if (annotated != null) {
|
||||
//noinspection ConstantConditions
|
||||
int parameterIndex = i - syntheticParameterCount;
|
||||
AnnotationCodegen.forParameter(parameterIndex, mv, innerClassConsumer, state)
|
||||
.genAnnotations(annotated, parameterSignature.getAsmType(), annotated.getReturnType());
|
||||
AnnotationCodegen.forParameter(parameterIndex, mv, memberCodegen, state, skipNullabilityAnnotations)
|
||||
.genAnnotations(annotated, parameterSignature.getAsmType(), annotated.getReturnType(), functionDescriptor, Collections.emptyList());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -606,7 +612,7 @@ public class FunctionCodegen {
|
||||
true, mv,
|
||||
method.getAsmMethod(),
|
||||
method.getOwner().getInternalName(),
|
||||
true);
|
||||
true, signature.getReturnType());
|
||||
methodEnd = new Label();
|
||||
}
|
||||
else {
|
||||
@@ -710,10 +716,8 @@ public class FunctionCodegen {
|
||||
@NotNull JvmDefaultMode jvmDefaultMode
|
||||
) {
|
||||
return OwnerKind.DEFAULT_IMPLS == context.getContextKind() &&
|
||||
JvmAnnotationUtilKt
|
||||
.isCompiledToJvmDefault(DescriptorUtils.unwrapFakeOverrideToAnyDeclaration(functionDescriptor),
|
||||
jvmDefaultMode) &&
|
||||
jvmDefaultMode.isCompatibility();
|
||||
jvmDefaultMode.isCompatibility() &&
|
||||
JvmAnnotationUtilKt.checkIsImplementationCompiledToJvmDefault(functionDescriptor, jvmDefaultMode);
|
||||
}
|
||||
|
||||
private static void generateLocalVariableTable(
|
||||
@@ -849,7 +853,8 @@ public class FunctionCodegen {
|
||||
@NotNull Method asmMethod,
|
||||
@NotNull String classToDelegateTo,
|
||||
int opcode,
|
||||
boolean isInterface
|
||||
boolean isInterface,
|
||||
@NotNull Type returnType
|
||||
) {
|
||||
InstructionAdapter iv = new InstructionAdapter(mv);
|
||||
Type[] argTypes = asmMethod.getArgumentTypes();
|
||||
@@ -871,7 +876,8 @@ public class FunctionCodegen {
|
||||
paramIndex += argType.getSize();
|
||||
}
|
||||
iv.visitMethodInsn(opcode, classToDelegateTo, asmMethod.getName(), asmMethod.getDescriptor(), isInterface);
|
||||
iv.areturn(asmMethod.getReturnType());
|
||||
StackValue.onStack(asmMethod.getReturnType()).coerceTo(returnType, null, iv);
|
||||
iv.areturn(returnType);
|
||||
}
|
||||
|
||||
private static void generateDelegateToStaticErasedVersion(
|
||||
@@ -910,7 +916,19 @@ public class FunctionCodegen {
|
||||
@NotNull String classToDelegateTo,
|
||||
boolean isInterfaceMethodCall
|
||||
) {
|
||||
generateDelegateToMethodBody(isStatic ? 0 : 1, mv, asmMethod, classToDelegateTo, Opcodes.INVOKESTATIC, isInterfaceMethodCall);
|
||||
generateDelegateToStaticMethodBody(isStatic, mv, asmMethod, classToDelegateTo, isInterfaceMethodCall, asmMethod.getReturnType());
|
||||
}
|
||||
|
||||
|
||||
private static void generateDelegateToStaticMethodBody(
|
||||
boolean isStatic,
|
||||
@NotNull MethodVisitor mv,
|
||||
@NotNull Method asmMethod,
|
||||
@NotNull String classToDelegateTo,
|
||||
boolean isInterfaceMethodCall,
|
||||
@NotNull Type returnType
|
||||
) {
|
||||
generateDelegateToMethodBody(isStatic ? 0 : 1, mv, asmMethod, classToDelegateTo, Opcodes.INVOKESTATIC, isInterfaceMethodCall, returnType);
|
||||
}
|
||||
|
||||
private static boolean needIndexForVar(JvmMethodParameterKind kind) {
|
||||
@@ -1656,7 +1674,9 @@ public class FunctionCodegen {
|
||||
|
||||
if (JvmAnnotationUtilKt.isCompiledToJvmDefault(memberDescriptor, mode)) {
|
||||
return (kind != OwnerKind.DEFAULT_IMPLS && !isSynthetic) ||
|
||||
(kind == OwnerKind.DEFAULT_IMPLS && (isSynthetic || mode.isCompatibility()));
|
||||
(kind == OwnerKind.DEFAULT_IMPLS &&
|
||||
(isSynthetic || //TODO: move synthetic method generation into interface
|
||||
(mode.isCompatibility() && !JvmAnnotationUtilKt.hasJvmDefaultNoCompatibilityAnnotation(containingDeclaration))));
|
||||
} else {
|
||||
switch (kind) {
|
||||
case DEFAULT_IMPLS: return true;
|
||||
|
||||
@@ -771,10 +771,12 @@ public class ImplementationBodyCodegen extends ClassBodyCodegen {
|
||||
|
||||
if (isNonCompanionObject(descriptor)) {
|
||||
StackValue.Field field = StackValue.createSingletonViaInstance(descriptor, typeMapper, INSTANCE_FIELD);
|
||||
v.newField(JvmDeclarationOriginKt.OtherOriginFromPure(myClass),
|
||||
ACC_PUBLIC | ACC_STATIC | ACC_FINAL,
|
||||
field.name, field.type.getDescriptor(), null, null);
|
||||
|
||||
FieldVisitor fv = v.newField(
|
||||
JvmDeclarationOriginKt.OtherOriginFromPure(myClass),
|
||||
ACC_PUBLIC | ACC_STATIC | ACC_FINAL,
|
||||
field.name, field.type.getDescriptor(), null, null
|
||||
);
|
||||
AnnotationCodegen.forField(fv, this, state).visitAnnotation(Type.getDescriptor(NotNull.class), false).visitEnd();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -816,10 +818,13 @@ public class ImplementationBodyCodegen extends ClassBodyCodegen {
|
||||
fieldAccessFlags |= ACC_SYNTHETIC;
|
||||
}
|
||||
StackValue.Field field = StackValue.singleton(companionObjectDescriptor, typeMapper);
|
||||
FieldVisitor fv = v.newField(JvmDeclarationOriginKt.OtherOrigin(companionObject == null ? myClass.getPsiOrParent() : companionObject),
|
||||
fieldAccessFlags, field.name, field.type.getDescriptor(), null, null);
|
||||
FieldVisitor fv = v.newField(
|
||||
JvmDeclarationOriginKt.OtherOrigin(companionObject == null ? myClass.getPsiOrParent() : companionObject),
|
||||
fieldAccessFlags, field.name, field.type.getDescriptor(), null, null
|
||||
);
|
||||
AnnotationCodegen.forField(fv, this, state).visitAnnotation(Type.getDescriptor(NotNull.class), false).visitEnd();
|
||||
if (fieldShouldBeDeprecated) {
|
||||
AnnotationCodegen.forField(fv, this, state).visitAnnotation("Ljava/lang/Deprecated;", true).visitEnd();
|
||||
AnnotationCodegen.forField(fv, this, state).visitAnnotation(Type.getDescriptor(Deprecated.class), true).visitEnd();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -17,8 +17,7 @@
|
||||
package org.jetbrains.kotlin.codegen
|
||||
|
||||
import com.intellij.util.ArrayUtil
|
||||
import org.jetbrains.kotlin.backend.common.bridges.findImplementationFromInterface
|
||||
import org.jetbrains.kotlin.backend.common.bridges.firstSuperMethodFromKotlin
|
||||
import org.jetbrains.kotlin.util.findImplementationFromInterface
|
||||
import org.jetbrains.kotlin.codegen.context.ClassContext
|
||||
import org.jetbrains.kotlin.codegen.state.GenerationState
|
||||
import org.jetbrains.kotlin.codegen.state.JvmMethodExceptionTypes
|
||||
@@ -29,6 +28,7 @@ import org.jetbrains.kotlin.resolve.DescriptorToSourceUtils
|
||||
import org.jetbrains.kotlin.resolve.jvm.diagnostics.JvmDeclarationOrigin
|
||||
import org.jetbrains.kotlin.resolve.jvm.diagnostics.JvmDeclarationOriginKind
|
||||
import org.jetbrains.kotlin.resolve.jvm.jvmSignature.JvmMethodSignature
|
||||
import org.jetbrains.kotlin.util.firstSuperMethodFromKotlin
|
||||
import org.jetbrains.org.objectweb.asm.MethodVisitor
|
||||
import org.jetbrains.org.objectweb.asm.Opcodes.*
|
||||
|
||||
|
||||
@@ -16,6 +16,8 @@ import org.jetbrains.kotlin.load.java.descriptors.JavaForKotlinOverridePropertyD
|
||||
import org.jetbrains.kotlin.resolve.DescriptorUtils
|
||||
import org.jetbrains.kotlin.resolve.jvm.annotations.isCompiledToJvmDefault
|
||||
import org.jetbrains.kotlin.resolve.jvm.annotations.hasPlatformDependentAnnotation
|
||||
import org.jetbrains.kotlin.util.findImplementationFromInterface
|
||||
import org.jetbrains.kotlin.util.findInterfaceImplementation
|
||||
|
||||
class DescriptorBasedFunctionHandleForJvm(
|
||||
descriptor: FunctionDescriptor,
|
||||
|
||||
@@ -438,7 +438,13 @@ public class PropertyCodegen {
|
||||
);
|
||||
|
||||
if (annotatedField != null) {
|
||||
AnnotationCodegen.forField(fv, memberCodegen, state)
|
||||
// Don't emit nullability annotations for backing field if:
|
||||
// - backing field is invisible from Java (private or synthetic);
|
||||
// - property is lateinit (since corresponding field is actually nullable).
|
||||
boolean skipNullabilityAnnotations =
|
||||
(modifiers & ACC_PRIVATE) != 0 || (modifiers & ACC_SYNTHETIC) != 0 ||
|
||||
propertyDescriptor.isLateInit();
|
||||
AnnotationCodegen.forField(fv, memberCodegen, state, skipNullabilityAnnotations)
|
||||
.genAnnotations(annotatedField, type, propertyDescriptor.getType());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ import org.jetbrains.kotlin.codegen.context.MethodContext
|
||||
import org.jetbrains.kotlin.codegen.serialization.JvmSerializationBindings.METHOD_FOR_FUNCTION
|
||||
import org.jetbrains.kotlin.codegen.serialization.JvmSerializerExtension
|
||||
import org.jetbrains.kotlin.codegen.state.GenerationState
|
||||
import org.jetbrains.kotlin.config.JVMConfigurationKeys
|
||||
import org.jetbrains.kotlin.config.LanguageFeature
|
||||
import org.jetbrains.kotlin.config.isReleaseCoroutines
|
||||
import org.jetbrains.kotlin.descriptors.*
|
||||
@@ -512,7 +513,8 @@ class CoroutineCodegenForLambda private constructor(
|
||||
containingClassInternalName = v.thisName,
|
||||
isForNamedFunction = false,
|
||||
languageVersionSettings = languageVersionSettings,
|
||||
disableTailCallOptimizationForFunctionReturningUnit = false
|
||||
disableTailCallOptimizationForFunctionReturningUnit = false,
|
||||
useOldSpilledVarTypeAnalysis = state.configuration.getBoolean(JVMConfigurationKeys.USE_OLD_SPILLED_VAR_TYPE_ANALYSIS)
|
||||
)
|
||||
val maybeWithForInline = if (forInline)
|
||||
SuspendForInlineCopyingMethodVisitor(stateMachineBuilder, access, name, desc, functionCodegen::newMethod)
|
||||
|
||||
@@ -5,14 +5,10 @@
|
||||
|
||||
package org.jetbrains.kotlin.codegen.coroutines
|
||||
|
||||
import org.jetbrains.kotlin.codegen.AsmUtil
|
||||
import org.jetbrains.kotlin.codegen.ClassBuilder
|
||||
import org.jetbrains.kotlin.codegen.StackValue
|
||||
import org.jetbrains.kotlin.codegen.TransformationMethodVisitor
|
||||
import org.jetbrains.kotlin.codegen.*
|
||||
import org.jetbrains.kotlin.codegen.inline.*
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.*
|
||||
import org.jetbrains.kotlin.codegen.optimization.fixStack.FixStackMethodTransformer
|
||||
import org.jetbrains.kotlin.codegen.linkWithLabel
|
||||
import org.jetbrains.kotlin.config.LanguageVersionSettings
|
||||
import org.jetbrains.kotlin.config.isReleaseCoroutines
|
||||
import org.jetbrains.kotlin.resolve.jvm.AsmTypes
|
||||
@@ -65,7 +61,9 @@ class CoroutineTransformerMethodVisitor(
|
||||
// May differ from containingClassInternalName in case of DefaultImpls
|
||||
private val internalNameForDispatchReceiver: String? = null,
|
||||
// JVM_IR backend generates $completion, while old backend does not
|
||||
private val putContinuationParameterToLvt: Boolean = true
|
||||
private val putContinuationParameterToLvt: Boolean = true,
|
||||
// New SourceInterpreter-less analyser can be somewhat unstable, disable it
|
||||
private val useOldSpilledVarTypeAnalysis: Boolean = false
|
||||
) : TransformationMethodVisitor(delegate, access, name, desc, signature, exceptions) {
|
||||
|
||||
private val classBuilderForCoroutineState: ClassBuilder by lazy(obtainClassBuilderForCoroutineState)
|
||||
@@ -594,7 +592,10 @@ class CoroutineTransformerMethodVisitor(
|
||||
|
||||
private fun spillVariables(suspensionPoints: List<SuspensionPoint>, methodNode: MethodNode): List<List<SpilledVariableDescriptor>> {
|
||||
val instructions = methodNode.instructions
|
||||
val frames = performRefinedTypeAnalysis(methodNode, containingClassInternalName)
|
||||
val frames =
|
||||
if (useOldSpilledVarTypeAnalysis) performRefinedTypeAnalysis(methodNode, containingClassInternalName)
|
||||
else performSpilledVariableFieldTypesAnalysis(methodNode, containingClassInternalName)
|
||||
|
||||
fun AbstractInsnNode.index() = instructions.indexOf(this)
|
||||
|
||||
// We postpone these actions because they change instruction indices that we use when obtaining frames
|
||||
@@ -642,11 +643,11 @@ class CoroutineTransformerMethodVisitor(
|
||||
.map { Pair(it, frame.getLocal(it)) }
|
||||
.filter { (index, value) ->
|
||||
(index == 0 && needDispatchReceiver && isForNamedFunction) ||
|
||||
(value != StrictBasicValue.UNINITIALIZED_VALUE && livenessFrame.isAlive(index))
|
||||
(value.type != null && livenessFrame.isAlive(index))
|
||||
}
|
||||
|
||||
for ((index, basicValue) in variablesToSpill) {
|
||||
if (basicValue === StrictBasicValue.NULL_VALUE) {
|
||||
if (basicValue == StrictBasicValue.NULL_VALUE) {
|
||||
postponedActions.add {
|
||||
with(instructions) {
|
||||
insert(suspension.tryCatchBlockEndLabelAfterSuspensionCall, withInstructionAdapter {
|
||||
@@ -658,7 +659,7 @@ class CoroutineTransformerMethodVisitor(
|
||||
continue
|
||||
}
|
||||
|
||||
val type = basicValue.type
|
||||
val type = basicValue.type!!
|
||||
val normalizedType = type.normalize()
|
||||
|
||||
val indexBySort = varsCountByType[normalizedType]?.plus(1) ?: 0
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package org.jetbrains.kotlin.codegen.coroutines
|
||||
|
||||
import org.jetbrains.kotlin.codegen.inline.nodeText
|
||||
import org.jetbrains.kotlin.codegen.optimization.boxing.isUnitInstance
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.MethodAnalyzer
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.asSequence
|
||||
@@ -13,169 +12,136 @@ import org.jetbrains.kotlin.codegen.optimization.common.removeAll
|
||||
import org.jetbrains.kotlin.codegen.optimization.fixStack.top
|
||||
import org.jetbrains.kotlin.codegen.optimization.transformer.MethodTransformer
|
||||
import org.jetbrains.kotlin.resolve.jvm.AsmTypes
|
||||
import org.jetbrains.kotlin.utils.addToStdlib.safeAs
|
||||
import org.jetbrains.org.objectweb.asm.Opcodes
|
||||
import org.jetbrains.org.objectweb.asm.Type
|
||||
import org.jetbrains.org.objectweb.asm.tree.*
|
||||
import org.jetbrains.org.objectweb.asm.tree.AbstractInsnNode
|
||||
import org.jetbrains.org.objectweb.asm.tree.LabelNode
|
||||
import org.jetbrains.org.objectweb.asm.tree.MethodNode
|
||||
import org.jetbrains.org.objectweb.asm.tree.VarInsnNode
|
||||
import org.jetbrains.org.objectweb.asm.tree.analysis.BasicInterpreter
|
||||
import org.jetbrains.org.objectweb.asm.tree.analysis.BasicValue
|
||||
import org.jetbrains.org.objectweb.asm.tree.analysis.Frame
|
||||
import java.util.*
|
||||
|
||||
private class PossibleSpilledValue(val source: AbstractInsnNode, type: Type?) : BasicValue(type) {
|
||||
val usages = mutableSetOf<AbstractInsnNode>()
|
||||
|
||||
override fun toString(): String = when {
|
||||
source.opcode == Opcodes.ALOAD -> "" + (source as VarInsnNode).`var`
|
||||
source.isUnitInstance() -> "U"
|
||||
else -> error("unreachable")
|
||||
}
|
||||
|
||||
override fun equals(other: Any?): Boolean =
|
||||
other is PossibleSpilledValue && source == other.source
|
||||
|
||||
override fun hashCode(): Int = super.hashCode() xor source.hashCode()
|
||||
}
|
||||
|
||||
private object NonSpillableValue : BasicValue(AsmTypes.OBJECT_TYPE) {
|
||||
override fun equals(other: Any?): Boolean = other is NonSpillableValue
|
||||
|
||||
override fun toString(): String = "N"
|
||||
}
|
||||
|
||||
private object ConstructedValue : BasicValue(AsmTypes.OBJECT_TYPE) {
|
||||
override fun equals(other: Any?): Boolean = other is ConstructedValue
|
||||
|
||||
override fun toString(): String = "C"
|
||||
}
|
||||
|
||||
fun BasicValue?.nonspillable(): BasicValue? = if (this?.type?.sort == Type.OBJECT) NonSpillableValue else this
|
||||
|
||||
private class RedundantSpillingInterpreter : BasicInterpreter(Opcodes.API_VERSION) {
|
||||
val possibleSpilledValues = mutableSetOf<PossibleSpilledValue>()
|
||||
|
||||
override fun newOperation(insn: AbstractInsnNode): BasicValue? {
|
||||
if (insn.opcode == Opcodes.NEW) return ConstructedValue
|
||||
val basicValue = super.newOperation(insn)
|
||||
return if (insn.isUnitInstance())
|
||||
// Unit instances come from inlining suspend functions returning Unit.
|
||||
// They can be spilled before they are eventually popped.
|
||||
// Track them.
|
||||
PossibleSpilledValue(insn, basicValue.type).also { possibleSpilledValues += it }
|
||||
else basicValue.nonspillable()
|
||||
}
|
||||
|
||||
override fun copyOperation(insn: AbstractInsnNode, value: BasicValue?): BasicValue? =
|
||||
when (value) {
|
||||
is ConstructedValue -> value
|
||||
is PossibleSpilledValue -> {
|
||||
value.usages += insn
|
||||
if (insn.opcode == Opcodes.ALOAD || insn.opcode == Opcodes.ASTORE) value
|
||||
else value.nonspillable()
|
||||
}
|
||||
else -> value?.nonspillable()
|
||||
}
|
||||
|
||||
override fun naryOperation(insn: AbstractInsnNode, values: MutableList<out BasicValue?>): BasicValue? {
|
||||
for (value in values.filterIsInstance<PossibleSpilledValue>()) {
|
||||
value.usages += insn
|
||||
}
|
||||
return super.naryOperation(insn, values)?.nonspillable()
|
||||
}
|
||||
|
||||
override fun merge(v: BasicValue?, w: BasicValue?): BasicValue? =
|
||||
if (v is PossibleSpilledValue && w is PossibleSpilledValue && v.source == w.source) v
|
||||
else v?.nonspillable()
|
||||
}
|
||||
|
||||
// Inliner emits a lot of locals during inlining.
|
||||
// Remove all of them since these locals are
|
||||
// 1) going to be spilled into continuation object
|
||||
// 2) breaking tail-call elimination
|
||||
/**
|
||||
* This pass removes unused Unit values. These typically occur as a result of inlining and could end up spilling
|
||||
* into the continuation object or break tail-call elimination.
|
||||
*
|
||||
* Concretely, we remove "GETSTATIC kotlin/Unit.INSTANCE" instructions if they are unused, or all uses are either
|
||||
* POP instructions, or ASTORE instructions to locals which are never read and are not named local variables.
|
||||
*
|
||||
* This pass does not touch [suspensionPoints], as later passes rely on the bytecode patterns around suspension points.
|
||||
*/
|
||||
internal class RedundantLocalsEliminationMethodTransformer(private val suspensionPoints: List<SuspensionPoint>) : MethodTransformer() {
|
||||
override fun transform(internalClassName: String, methodNode: MethodNode) {
|
||||
val interpreter = RedundantSpillingInterpreter()
|
||||
val frames = MethodAnalyzer<BasicValue>(internalClassName, methodNode, interpreter).analyze()
|
||||
val interpreter = UnitSourceInterpreter(methodNode.localVariables?.mapTo(mutableSetOf()) { it.index } ?: setOf())
|
||||
val frames = interpreter.run(internalClassName, methodNode)
|
||||
|
||||
// Mark all unused instructions for deletion (except for labels which may be used in debug information)
|
||||
val toDelete = mutableSetOf<AbstractInsnNode>()
|
||||
for (spilledValue in interpreter.possibleSpilledValues.filter { it.usages.isNotEmpty() }) {
|
||||
@Suppress("UNCHECKED_CAST")
|
||||
val aloads = spilledValue.usages.filter { it.opcode == Opcodes.ALOAD } as List<VarInsnNode>
|
||||
|
||||
if (aloads.isEmpty()) continue
|
||||
|
||||
val slot = aloads.first().`var`
|
||||
|
||||
if (aloads.any { it.`var` != slot }) continue
|
||||
for (aload in aloads) {
|
||||
methodNode.instructions.set(aload, spilledValue.source.clone())
|
||||
}
|
||||
|
||||
toDelete.addAll(spilledValue.usages.filter { it.opcode == Opcodes.ASTORE })
|
||||
toDelete.add(spilledValue.source)
|
||||
methodNode.instructions.asSequence().zip(frames.asSequence()).mapNotNullTo(toDelete) { (insn, frame) ->
|
||||
insn.takeIf { frame == null && insn !is LabelNode }
|
||||
}
|
||||
|
||||
for (pop in methodNode.instructions.asSequence().filter { it.opcode == Opcodes.POP }) {
|
||||
val value = (frames[methodNode.instructions.indexOf(pop)]?.top() as? PossibleSpilledValue) ?: continue
|
||||
if (value.usages.isEmpty() && value.source !in suspensionPoints) {
|
||||
toDelete.add(pop)
|
||||
toDelete.add(value.source)
|
||||
}
|
||||
}
|
||||
|
||||
// Remove unreachable instructions to simplify further analyses
|
||||
for (index in frames.indices) {
|
||||
if (frames[index] == null) {
|
||||
val insn = methodNode.instructions[index]
|
||||
if (insn !is LabelNode) {
|
||||
toDelete.add(insn)
|
||||
}
|
||||
// Mark all spillable "GETSTATIC kotlin/Unit.INSTANCE" instructions for deletion
|
||||
for ((unit, uses) in interpreter.unitUsageInformation) {
|
||||
if (unit !in interpreter.unspillableUnitValues && unit !in suspensionPoints) {
|
||||
toDelete += unit
|
||||
toDelete += uses
|
||||
}
|
||||
}
|
||||
|
||||
methodNode.instructions.removeAll(toDelete)
|
||||
}
|
||||
|
||||
private fun AbstractInsnNode.clone() = when (this) {
|
||||
is FieldInsnNode -> FieldInsnNode(opcode, owner, name, desc)
|
||||
is VarInsnNode -> VarInsnNode(opcode, `var`)
|
||||
is InsnNode -> InsnNode(opcode)
|
||||
is TypeInsnNode -> TypeInsnNode(opcode, desc)
|
||||
else -> error("clone of $this is not implemented yet")
|
||||
}
|
||||
}
|
||||
|
||||
// Handy debugging routing
|
||||
@Suppress("unused")
|
||||
fun MethodNode.nodeTextWithFrames(frames: Array<*>): String {
|
||||
var insns = nodeText.split("\n")
|
||||
val first = insns.indexOfLast { it.trim().startsWith("@") } + 1
|
||||
var last = insns.indexOfFirst { it.trim().startsWith("LOCALVARIABLE") }
|
||||
if (last < 0) last = insns.size
|
||||
val prefix = insns.subList(0, first).joinToString(separator = "\n")
|
||||
val postfix = insns.subList(last, insns.size).joinToString(separator = "\n")
|
||||
insns = insns.subList(first, last)
|
||||
if (insns.any { it.contains("TABLESWITCH") }) {
|
||||
var insideTableSwitch = false
|
||||
var buffer = ""
|
||||
val res = arrayListOf<String>()
|
||||
for (insn in insns) {
|
||||
if (insn.contains("TABLESWITCH")) {
|
||||
insideTableSwitch = true
|
||||
}
|
||||
if (insideTableSwitch) {
|
||||
buffer += insn
|
||||
if (insn.contains("default")) {
|
||||
insideTableSwitch = false
|
||||
res += buffer
|
||||
buffer = ""
|
||||
continue
|
||||
}
|
||||
} else {
|
||||
res += insn
|
||||
// A version of SourceValue which inherits from BasicValue and is only used for Unit values.
|
||||
private class UnitValue(val insns: Set<AbstractInsnNode>) : BasicValue(AsmTypes.OBJECT_TYPE) {
|
||||
constructor(insn: AbstractInsnNode) : this(Collections.singleton(insn))
|
||||
|
||||
override fun equals(other: Any?): Boolean = other is UnitValue && insns == other.insns
|
||||
override fun hashCode() = Objects.hash(insns)
|
||||
override fun toString() = "U"
|
||||
}
|
||||
|
||||
// A specialized SourceInterpreter which only keeps track of the use sites for Unit values which are exclusively used as
|
||||
// arguments to POP and unused ASTORE instructions.
|
||||
private class UnitSourceInterpreter(private val localVariables: Set<Int>) : BasicInterpreter(Opcodes.API_VERSION) {
|
||||
// All unit values with visible use-sites.
|
||||
val unspillableUnitValues = mutableSetOf<AbstractInsnNode>()
|
||||
|
||||
// Map from unit values to ASTORE/POP use-sites.
|
||||
val unitUsageInformation = mutableMapOf<AbstractInsnNode, MutableSet<AbstractInsnNode>>()
|
||||
|
||||
private fun markUnspillable(value: BasicValue?) =
|
||||
value?.safeAs<UnitValue>()?.let { unspillableUnitValues += it.insns }
|
||||
|
||||
private fun collectUnitUsage(use: AbstractInsnNode, value: UnitValue) {
|
||||
for (def in value.insns) {
|
||||
if (def !in unspillableUnitValues) {
|
||||
unitUsageInformation.getOrPut(def) { mutableSetOf() } += use
|
||||
}
|
||||
}
|
||||
insns = res
|
||||
}
|
||||
return prefix + "\n" + insns.withIndex().joinToString(separator = "\n") { (index, insn) ->
|
||||
if (index >= frames.size) "N/A\t$insn" else "${frames[index]}\t$insn"
|
||||
} + "\n" + postfix
|
||||
|
||||
fun run(internalClassName: String, methodNode: MethodNode): Array<Frame<BasicValue>?> {
|
||||
val frames = MethodAnalyzer<BasicValue>(internalClassName, methodNode, this).analyze()
|
||||
// The ASM analyzer does not visit POP instructions, so we do so here.
|
||||
for ((insn, frame) in methodNode.instructions.asSequence().zip(frames.asSequence())) {
|
||||
if (frame != null && insn.opcode == Opcodes.POP) {
|
||||
val value = frame.top()
|
||||
value.safeAs<UnitValue>()?.let { collectUnitUsage(insn, it) }
|
||||
}
|
||||
}
|
||||
return frames
|
||||
}
|
||||
|
||||
override fun newOperation(insn: AbstractInsnNode?): BasicValue =
|
||||
if (insn?.isUnitInstance() == true) UnitValue(insn) else super.newOperation(insn)
|
||||
|
||||
override fun copyOperation(insn: AbstractInsnNode, value: BasicValue?): BasicValue? {
|
||||
if (value is UnitValue) {
|
||||
if (insn is VarInsnNode && insn.opcode == Opcodes.ASTORE && insn.`var` !in localVariables) {
|
||||
collectUnitUsage(insn, value)
|
||||
// We track the stored value in case it is subsequently read.
|
||||
return value
|
||||
}
|
||||
unspillableUnitValues += value.insns
|
||||
}
|
||||
return super.copyOperation(insn, value)
|
||||
}
|
||||
|
||||
override fun unaryOperation(insn: AbstractInsnNode, value: BasicValue?): BasicValue? {
|
||||
markUnspillable(value)
|
||||
return super.unaryOperation(insn, value)
|
||||
}
|
||||
|
||||
override fun binaryOperation(insn: AbstractInsnNode, value1: BasicValue?, value2: BasicValue?): BasicValue? {
|
||||
markUnspillable(value1)
|
||||
markUnspillable(value2)
|
||||
return super.binaryOperation(insn, value1, value2)
|
||||
}
|
||||
|
||||
override fun ternaryOperation(insn: AbstractInsnNode, value1: BasicValue?, value2: BasicValue?, value3: BasicValue?): BasicValue? {
|
||||
markUnspillable(value1)
|
||||
markUnspillable(value2)
|
||||
markUnspillable(value3)
|
||||
return super.ternaryOperation(insn, value1, value2, value3)
|
||||
}
|
||||
|
||||
override fun naryOperation(insn: AbstractInsnNode, values: List<BasicValue>?): BasicValue? {
|
||||
values?.forEach(this::markUnspillable)
|
||||
return super.naryOperation(insn, values)
|
||||
}
|
||||
|
||||
override fun merge(value1: BasicValue?, value2: BasicValue?): BasicValue? =
|
||||
if (value1 is UnitValue && value2 is UnitValue) {
|
||||
UnitValue(value1.insns.union(value2.insns))
|
||||
} else {
|
||||
// Mark unit values as unspillable if we merge them with non-unit values here.
|
||||
// This is conservative since the value could turn out to be unused.
|
||||
markUnspillable(value1)
|
||||
markUnspillable(value2)
|
||||
super.merge(value1, value2)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,160 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package org.jetbrains.kotlin.codegen.coroutines
|
||||
|
||||
import org.jetbrains.kotlin.codegen.StackValue
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.MethodAnalyzer
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.OptimizationBasicInterpreter
|
||||
import org.jetbrains.org.objectweb.asm.Label
|
||||
import org.jetbrains.org.objectweb.asm.Opcodes
|
||||
import org.jetbrains.org.objectweb.asm.Type
|
||||
import org.jetbrains.org.objectweb.asm.commons.InstructionAdapter
|
||||
import org.jetbrains.org.objectweb.asm.tree.*
|
||||
import org.jetbrains.org.objectweb.asm.tree.analysis.BasicValue
|
||||
import org.jetbrains.org.objectweb.asm.tree.analysis.Frame
|
||||
|
||||
// BasicValue interpreter from ASM does not distinct 'int' types from other int-like types like 'byte' or 'boolean',
|
||||
// neither do HotSpot and JVM spec.
|
||||
// But it seems like Dalvik does not follow it, and spilling boolean value into an 'int' field fails with VerifyError on Android 4,
|
||||
// so this function calculates refined frames' markup.
|
||||
// Note that type of some values is only possible to determine by their usages (e.g. ICONST_1, BALOAD both may push boolean or byte on stack)
|
||||
// In this case, coerce the type of the value.
|
||||
|
||||
internal class IloadedValue(val insns: Set<VarInsnNode>) : BasicValue(Type.INT_TYPE)
|
||||
|
||||
private class IntLikeCoerceInterpreter : OptimizationBasicInterpreter() {
|
||||
val needsToBeCoerced = mutableMapOf<VarInsnNode, Type>()
|
||||
|
||||
private fun coerce(value: IloadedValue, type: Type) {
|
||||
for (insn in value.insns) {
|
||||
needsToBeCoerced[insn] = type
|
||||
}
|
||||
}
|
||||
|
||||
override fun copyOperation(insn: AbstractInsnNode, value: BasicValue?): BasicValue? =
|
||||
when {
|
||||
insn.opcode == Opcodes.ILOAD -> IloadedValue(setOf(insn as VarInsnNode))
|
||||
value == null -> null
|
||||
else -> BasicValue(value.type)
|
||||
}
|
||||
|
||||
override fun binaryOperation(insn: AbstractInsnNode, v: BasicValue, w: BasicValue): BasicValue? {
|
||||
if (insn.opcode == Opcodes.PUTFIELD) {
|
||||
val expectedType = Type.getType((insn as FieldInsnNode).desc)
|
||||
if (w is IloadedValue && expectedType.isIntLike()) {
|
||||
coerce(w, expectedType)
|
||||
}
|
||||
}
|
||||
return super.binaryOperation(insn, v, w)
|
||||
}
|
||||
|
||||
override fun unaryOperation(insn: AbstractInsnNode, value: BasicValue?): BasicValue? {
|
||||
if (insn.opcode == Opcodes.PUTSTATIC) {
|
||||
val expectedType = Type.getType((insn as FieldInsnNode).desc)
|
||||
if (value is IloadedValue && expectedType.isIntLike()) {
|
||||
coerce(value, expectedType)
|
||||
}
|
||||
}
|
||||
return super.unaryOperation(insn, value)
|
||||
}
|
||||
|
||||
override fun naryOperation(insn: AbstractInsnNode, values: MutableList<out BasicValue?>): BasicValue? {
|
||||
fun checkTypes(argTypes: Array<Type>, withReceiver: Boolean) {
|
||||
val offset = if (withReceiver) 1 else 0
|
||||
for ((index, argType) in argTypes.withIndex()) {
|
||||
val value = values[index + offset] ?: continue
|
||||
if (argType.isIntLike() && value is IloadedValue) {
|
||||
coerce(value, argType)
|
||||
}
|
||||
}
|
||||
}
|
||||
when (insn.opcode) {
|
||||
Opcodes.INVOKEDYNAMIC -> {
|
||||
checkTypes(Type.getArgumentTypes((insn as InvokeDynamicInsnNode).desc), false)
|
||||
}
|
||||
Opcodes.INVOKESTATIC -> {
|
||||
checkTypes(Type.getArgumentTypes((insn as MethodInsnNode).desc), false)
|
||||
}
|
||||
Opcodes.INVOKEVIRTUAL, Opcodes.INVOKEINTERFACE, Opcodes.INVOKESPECIAL -> {
|
||||
checkTypes(Type.getArgumentTypes((insn as MethodInsnNode).desc), true)
|
||||
}
|
||||
}
|
||||
return super.naryOperation(insn, values)
|
||||
}
|
||||
|
||||
override fun ternaryOperation(insn: AbstractInsnNode, arrayref: BasicValue?, index: BasicValue?, value: BasicValue?): BasicValue? {
|
||||
when (insn.opcode) {
|
||||
Opcodes.BASTORE -> {
|
||||
if (value is IloadedValue) {
|
||||
val type = if (arrayref?.type?.descriptor == "[Z") Type.BOOLEAN_TYPE else Type.BYTE_TYPE
|
||||
coerce(value, type)
|
||||
}
|
||||
}
|
||||
Opcodes.CASTORE -> {
|
||||
if (value is IloadedValue) {
|
||||
coerce(value, Type.CHAR_TYPE)
|
||||
}
|
||||
}
|
||||
Opcodes.SASTORE -> {
|
||||
if (value is IloadedValue) {
|
||||
coerce(value, Type.SHORT_TYPE)
|
||||
}
|
||||
}
|
||||
}
|
||||
return super.ternaryOperation(insn, arrayref, index, value)
|
||||
}
|
||||
|
||||
override fun merge(v: BasicValue, w: BasicValue): BasicValue =
|
||||
when {
|
||||
v is IloadedValue && w is IloadedValue && v.type == w.type -> {
|
||||
val insns = v.insns + w.insns
|
||||
insns.find { it in needsToBeCoerced }?.let {
|
||||
val type = needsToBeCoerced[it]!!
|
||||
coerce(v, type)
|
||||
coerce(w, type)
|
||||
}
|
||||
IloadedValue(insns)
|
||||
}
|
||||
v.type == w.type -> {
|
||||
if (w is IloadedValue) w else v
|
||||
}
|
||||
else -> super.merge(v, w)
|
||||
}
|
||||
}
|
||||
|
||||
internal fun performSpilledVariableFieldTypesAnalysis(
|
||||
methodNode: MethodNode,
|
||||
thisName: String
|
||||
): Array<out Frame<BasicValue>?> {
|
||||
val interpreter = IntLikeCoerceInterpreter()
|
||||
MethodAnalyzer(thisName, methodNode, interpreter).analyze()
|
||||
for ((insn, type) in interpreter.needsToBeCoerced) {
|
||||
methodNode.instructions.insert(insn, withInstructionAdapter { coerceInt(type, this) })
|
||||
}
|
||||
return MethodAnalyzer(thisName, methodNode, OptimizationBasicInterpreter()).analyze()
|
||||
}
|
||||
|
||||
private fun coerceInt(to: Type, v: InstructionAdapter) {
|
||||
if (to == Type.BOOLEAN_TYPE) {
|
||||
with(v) {
|
||||
val zeroLabel = Label()
|
||||
val resLabel = Label()
|
||||
ifeq(zeroLabel)
|
||||
iconst(1)
|
||||
goTo(resLabel)
|
||||
mark(zeroLabel)
|
||||
iconst(0)
|
||||
mark(resLabel)
|
||||
}
|
||||
} else {
|
||||
StackValue.coerce(Type.INT_TYPE, to, v)
|
||||
}
|
||||
}
|
||||
|
||||
private fun Type.isIntLike(): Boolean = when (sort) {
|
||||
Type.BOOLEAN, Type.BYTE, Type.CHAR, Type.SHORT -> true
|
||||
else -> false
|
||||
}
|
||||
@@ -12,6 +12,7 @@ import org.jetbrains.kotlin.codegen.inline.addFakeContinuationConstructorCallMar
|
||||
import org.jetbrains.kotlin.codegen.inline.coroutines.FOR_INLINE_SUFFIX
|
||||
import org.jetbrains.kotlin.codegen.inline.preprocessSuspendMarkers
|
||||
import org.jetbrains.kotlin.codegen.state.GenerationState
|
||||
import org.jetbrains.kotlin.config.JVMConfigurationKeys
|
||||
import org.jetbrains.kotlin.config.JVMConstructorCallNormalizationMode
|
||||
import org.jetbrains.kotlin.config.LanguageVersionSettings
|
||||
import org.jetbrains.kotlin.config.languageVersionSettings
|
||||
@@ -95,7 +96,8 @@ class SuspendFunctionGenerationStrategy(
|
||||
languageVersionSettings = languageVersionSettings,
|
||||
disableTailCallOptimizationForFunctionReturningUnit = originalSuspendDescriptor.returnType?.isUnit() == true &&
|
||||
originalSuspendDescriptor.overriddenDescriptors.isNotEmpty() &&
|
||||
!originalSuspendDescriptor.allOverriddenFunctionsReturnUnit()
|
||||
!originalSuspendDescriptor.allOverriddenFunctionsReturnUnit(),
|
||||
useOldSpilledVarTypeAnalysis = state.configuration.getBoolean(JVMConfigurationKeys.USE_OLD_SPILLED_VAR_TYPE_ANALYSIS)
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
|
||||
@@ -12,6 +12,7 @@ import org.jetbrains.kotlin.codegen.coroutines.*
|
||||
import org.jetbrains.kotlin.codegen.inline.*
|
||||
import org.jetbrains.kotlin.codegen.optimization.common.asSequence
|
||||
import org.jetbrains.kotlin.codegen.optimization.transformer.MethodTransformer
|
||||
import org.jetbrains.kotlin.config.JVMConfigurationKeys
|
||||
import org.jetbrains.kotlin.config.isReleaseCoroutines
|
||||
import org.jetbrains.kotlin.descriptors.ClassDescriptor
|
||||
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor
|
||||
@@ -95,7 +96,8 @@ class CoroutineTransformer(
|
||||
shouldPreserveClassInitialization = state.constructorCallNormalizationMode.shouldPreserveClassInitialization,
|
||||
containingClassInternalName = classBuilder.thisName,
|
||||
isForNamedFunction = false,
|
||||
disableTailCallOptimizationForFunctionReturningUnit = false
|
||||
disableTailCallOptimizationForFunctionReturningUnit = false,
|
||||
useOldSpilledVarTypeAnalysis = state.configuration.getBoolean(JVMConfigurationKeys.USE_OLD_SPILLED_VAR_TYPE_ANALYSIS)
|
||||
)
|
||||
|
||||
if (generateForInline)
|
||||
@@ -131,7 +133,8 @@ class CoroutineTransformer(
|
||||
needDispatchReceiver = true,
|
||||
internalNameForDispatchReceiver = classBuilder.thisName,
|
||||
disableTailCallOptimizationForFunctionReturningUnit = disableTailCallOptimization,
|
||||
putContinuationParameterToLvt = !state.isIrBackend
|
||||
putContinuationParameterToLvt = !state.isIrBackend,
|
||||
useOldSpilledVarTypeAnalysis = state.configuration.getBoolean(JVMConfigurationKeys.USE_OLD_SPILLED_VAR_TYPE_ANALYSIS)
|
||||
)
|
||||
|
||||
if (generateForInline)
|
||||
|
||||
@@ -94,7 +94,13 @@ class JvmSerializerExtension @JvmOverloads constructor(
|
||||
writeVersionRequirementForJvmDefaultIfNeeded(descriptor, proto, versionRequirementTable)
|
||||
|
||||
if (jvmDefaultMode.forAllMethodsWithBody && isInterface(descriptor)) {
|
||||
proto.setExtension(JvmProtoBuf.jvmClassFlags, JvmFlags.getClassFlags(true))
|
||||
proto.setExtension(
|
||||
JvmProtoBuf.jvmClassFlags,
|
||||
JvmFlags.getClassFlags(
|
||||
jvmDefaultMode.forAllMethodsWithBody,
|
||||
JvmDefaultMode.ALL_COMPATIBILITY == jvmDefaultMode
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -16,16 +16,27 @@
|
||||
|
||||
package org.jetbrains.kotlin.codegen.signature
|
||||
|
||||
import org.jetbrains.kotlin.builtins.PrimitiveType
|
||||
import org.jetbrains.kotlin.codegen.AsmUtil
|
||||
import org.jetbrains.kotlin.load.kotlin.JvmTypeFactory
|
||||
import org.jetbrains.kotlin.resolve.jvm.AsmTypes
|
||||
import org.jetbrains.org.objectweb.asm.Type
|
||||
|
||||
object AsmTypeFactory : JvmTypeFactory<Type> {
|
||||
override fun boxType(possiblyPrimitiveType: Type) = AsmUtil.boxType(possiblyPrimitiveType)
|
||||
override fun createFromString(representation: String) = Type.getType(representation)
|
||||
override fun createObjectType(internalName: String) = Type.getObjectType(internalName)
|
||||
override fun toString(type: Type) = type.descriptor
|
||||
override fun boxType(possiblyPrimitiveType: Type): Type =
|
||||
AsmUtil.boxType(possiblyPrimitiveType)
|
||||
|
||||
override fun createFromString(representation: String): Type =
|
||||
Type.getType(representation)
|
||||
|
||||
override fun createPrimitiveType(primitiveType: PrimitiveType): Type =
|
||||
AsmTypes.valueTypeForPrimitive(primitiveType)
|
||||
|
||||
override fun createObjectType(internalName: String): Type =
|
||||
Type.getObjectType(internalName)
|
||||
|
||||
override fun toString(type: Type): String =
|
||||
type.descriptor
|
||||
|
||||
override val javaLangClassType: Type
|
||||
get() = AsmTypes.JAVA_CLASS_TYPE
|
||||
|
||||
@@ -51,7 +51,7 @@ class BuiltInsSerializer(dependOnOldBuiltIns: Boolean) : MetadataSerializer(Buil
|
||||
put(CommonConfigurationKeys.MODULE_NAME, "module for built-ins serialization")
|
||||
}
|
||||
|
||||
val environment = KotlinCoreEnvironment.createForTests(rootDisposable, configuration, EnvironmentConfigFiles.JVM_CONFIG_FILES)
|
||||
val environment = KotlinCoreEnvironment.createForProduction(rootDisposable, configuration, EnvironmentConfigFiles.JVM_CONFIG_FILES)
|
||||
|
||||
serialize(environment)
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ package org.jetbrains.kotlin.serialization.builtins
|
||||
import org.jetbrains.kotlin.metadata.ProtoBuf
|
||||
import org.jetbrains.kotlin.metadata.builtins.BuiltInsBinaryVersion
|
||||
import org.jetbrains.kotlin.metadata.deserialization.BinaryVersion
|
||||
import org.jetbrains.kotlin.serialization.AnnotationSerializer
|
||||
import org.jetbrains.kotlin.serialization.KotlinSerializerExtensionBase
|
||||
import org.jetbrains.kotlin.serialization.deserialization.builtins.BuiltInSerializerProtocol
|
||||
import org.jetbrains.kotlin.types.KotlinType
|
||||
@@ -31,20 +32,29 @@ class BuiltInsSerializerExtension : KotlinSerializerExtensionBase(BuiltInSeriali
|
||||
"CharRange" to "kotlin/ranges/CharRange"
|
||||
)
|
||||
|
||||
override fun createAnnotationSerializer(): AnnotationSerializer = object : AnnotationSerializer(stringTable) {
|
||||
override fun ignoreAnnotation(type: KotlinType): Boolean =
|
||||
type.presentableName == "JvmStatic" || type.presentableName == "JvmField" || super.ignoreAnnotation(type)
|
||||
}
|
||||
|
||||
override val metadataVersion: BinaryVersion
|
||||
get() = BuiltInsBinaryVersion.INSTANCE
|
||||
|
||||
override fun shouldUseTypeTable(): Boolean = true
|
||||
|
||||
override fun serializeErrorType(type: KotlinType, builder: ProtoBuf.Type.Builder) {
|
||||
val unwrapped = type.unwrap()
|
||||
if (unwrapped !is UnresolvedType) {
|
||||
throw UnsupportedOperationException("Error types which are not UnresolvedType instances are not supported here: $unwrapped")
|
||||
}
|
||||
|
||||
val className = shortNameToClassId[unwrapped.presentableName]
|
||||
?: throw UnsupportedOperationException("Unsupported unresolved type: $unwrapped")
|
||||
val className = shortNameToClassId[type.presentableName]
|
||||
?: throw UnsupportedOperationException("Unsupported unresolved type: ${type.unwrap()}")
|
||||
|
||||
builder.className = stringTable.getQualifiedClassNameIndex(className, false)
|
||||
}
|
||||
|
||||
private val KotlinType.presentableName: String
|
||||
get() {
|
||||
val unwrapped = unwrap()
|
||||
if (unwrapped !is UnresolvedType) {
|
||||
throw UnsupportedOperationException("Error types which are not UnresolvedType instances are not supported here: $unwrapped")
|
||||
}
|
||||
return unwrapped.presentableName
|
||||
}
|
||||
}
|
||||
|
||||
@@ -340,6 +340,12 @@ abstract class CommonCompilerArguments : CommonToolArguments() {
|
||||
)
|
||||
var explicitApi: String by FreezableVar(ExplicitApiMode.DISABLED.state)
|
||||
|
||||
@Argument(
|
||||
value = "-Xdeserialize-fake-overrides",
|
||||
description = "Fallback to deserializing fake overrides"
|
||||
)
|
||||
var deserializeFakeOverrides: Boolean by FreezableVar(false)
|
||||
|
||||
open fun configureAnalysisFlags(collector: MessageCollector): MutableMap<AnalysisFlag<*>, Any> {
|
||||
return HashMap<AnalysisFlag<*>, Any>().apply {
|
||||
put(AnalysisFlags.skipMetadataVersionCheck, skipMetadataVersionCheck)
|
||||
|
||||
@@ -135,6 +135,9 @@ class K2JSCompilerArguments : CommonCompilerArguments() {
|
||||
)
|
||||
var irModuleName: String? by NullableStringFreezableVar(null)
|
||||
|
||||
@Argument(value = "-Xir-per-module", description = "Splits generated .js per-module")
|
||||
var irPerModule: Boolean by FreezableVar(false)
|
||||
|
||||
@Argument(
|
||||
value = "-Xinclude",
|
||||
valueDescription = "<path>",
|
||||
@@ -169,6 +172,9 @@ class K2JSCompilerArguments : CommonCompilerArguments() {
|
||||
@Argument(value = "-Xenable-js-scripting", description = "Enable experimental support of .kts files using K/JS (with -Xir only)")
|
||||
var enableJsScripting: Boolean by FreezableVar(false)
|
||||
|
||||
@Argument(value = "-Xdisable-fake-override-validator", description = "Disable IR fake override validator")
|
||||
var disableFakeOverrideValidator: Boolean by FreezableVar(false)
|
||||
|
||||
override fun checkIrSupport(languageVersionSettings: LanguageVersionSettings, collector: MessageCollector) {
|
||||
if (!isIrBackendEnabled()) return
|
||||
|
||||
|
||||
@@ -369,6 +369,12 @@ class K2JVMCompilerArguments : CommonCompilerArguments() {
|
||||
)
|
||||
var repeatCompileModules: String? by NullableStringFreezableVar(null)
|
||||
|
||||
@Argument(
|
||||
value = "-Xuse-old-spilled-var-type-analysis",
|
||||
description = "Use old, SourceInterpreter-based analysis for fields, used for spilled variables in coroutines"
|
||||
)
|
||||
var useOldSpilledVarTypeAnalysis: Boolean by FreezableVar(false)
|
||||
|
||||
override fun configureAnalysisFlags(collector: MessageCollector): MutableMap<AnalysisFlag<*>, Any> {
|
||||
val result = super.configureAnalysisFlags(collector)
|
||||
result[JvmAnalysisFlags.strictMetadataVersionSemantics] = strictMetadataVersionSemantics
|
||||
|
||||
@@ -63,8 +63,8 @@ private interface ArgsConverter<T> {
|
||||
}
|
||||
|
||||
fun tryConvertSingle(parameter: KParameter, arg: NamedArgument<T>): Result
|
||||
fun tryConvertVararg(parameter: KParameter, firstArg: NamedArgument<T>, restArgsIt: Iterator<NamedArgument<T>>): Result
|
||||
fun tryConvertTail(parameter: KParameter, firstArg: NamedArgument<T>, restArgsIt: Iterator<NamedArgument<T>>): Result
|
||||
fun tryConvertVararg(parameter: KParameter, firstArg: NamedArgument<T>, restArgs: Sequence<NamedArgument<T>>): Result
|
||||
fun tryConvertTail(parameter: KParameter, firstArg: NamedArgument<T>, restArgs: Sequence<NamedArgument<T>>): Result
|
||||
}
|
||||
|
||||
private enum class ArgsTraversalState { UNNAMED, NAMED, TAIL }
|
||||
@@ -77,7 +77,7 @@ private fun <T> tryCreateCallableMapping(
|
||||
val res = mutableMapOf<KParameter, Any?>()
|
||||
var state = ArgsTraversalState.UNNAMED
|
||||
val unboundParams = callable.parameters.toMutableList()
|
||||
val argIt = args.iterator()
|
||||
val argIt = LookAheadIterator(args.iterator())
|
||||
while (argIt.hasNext()) {
|
||||
if (unboundParams.isEmpty()) return null // failed to match: no param left for the arg
|
||||
val arg = argIt.next()
|
||||
@@ -102,7 +102,11 @@ private fun <T> tryCreateCallableMapping(
|
||||
res[par] = cvtRes.v
|
||||
} else if (par.type.jvmErasure.java.isArray) {
|
||||
// try vararg
|
||||
val cvtVRes = converter.tryConvertVararg(par, arg, argIt)
|
||||
|
||||
// Collect all the arguments that do not have a name
|
||||
val unnamed = argIt.sequenceUntil { it.name != null }
|
||||
|
||||
val cvtVRes = converter.tryConvertVararg(par, arg, unnamed)
|
||||
if (cvtVRes is ArgsConverter.Result.Success) {
|
||||
res[par] = cvtVRes.v
|
||||
} else return null // failed to match: no suitable param for unnamed arg
|
||||
@@ -121,7 +125,7 @@ private fun <T> tryCreateCallableMapping(
|
||||
ArgsTraversalState.TAIL -> {
|
||||
assert(arg.name == null)
|
||||
val par = unboundParams.removeAt(unboundParams.lastIndex)
|
||||
val cvtVRes = converter.tryConvertTail(par, arg, argIt)
|
||||
val cvtVRes = converter.tryConvertTail(par, arg, argIt.asSequence())
|
||||
if (cvtVRes is ArgsConverter.Result.Success) {
|
||||
if (argIt.hasNext()) return null // failed to match: not all tail args are consumed
|
||||
res[par] = cvtVRes.v
|
||||
@@ -162,7 +166,7 @@ private class StringArgsConverter : ArgsConverter<String> {
|
||||
override fun tryConvertVararg(
|
||||
parameter: KParameter,
|
||||
firstArg: NamedArgument<String>,
|
||||
restArgsIt: Iterator<NamedArgument<String>>
|
||||
restArgs: Sequence<NamedArgument<String>>
|
||||
): ArgsConverter.Result {
|
||||
fun convertPrimitivesArray(type: KType, args: Sequence<String?>): Any? =
|
||||
when (type.classifier) {
|
||||
@@ -179,7 +183,7 @@ private class StringArgsConverter : ArgsConverter<String> {
|
||||
|
||||
val parameterType = parameter.type
|
||||
if (parameterType.jvmErasure.java.isArray) {
|
||||
val argsSequence = sequenceOf(firstArg.value) + restArgsIt.asSequence().map { it.value }
|
||||
val argsSequence = sequenceOf(firstArg.value) + restArgs.map { it.value }
|
||||
val primArrayArgCandidate = convertPrimitivesArray(parameterType, argsSequence)
|
||||
if (primArrayArgCandidate != null)
|
||||
return ArgsConverter.Result.Success(primArrayArgCandidate)
|
||||
@@ -195,9 +199,9 @@ private class StringArgsConverter : ArgsConverter<String> {
|
||||
override fun tryConvertTail(
|
||||
parameter: KParameter,
|
||||
firstArg: NamedArgument<String>,
|
||||
restArgsIt: Iterator<NamedArgument<String>>
|
||||
restArgs: Sequence<NamedArgument<String>>
|
||||
): ArgsConverter.Result =
|
||||
tryConvertVararg(parameter, firstArg, restArgsIt)
|
||||
tryConvertVararg(parameter, firstArg, restArgs)
|
||||
}
|
||||
|
||||
private class AnyArgsConverter : ArgsConverter<Any> {
|
||||
@@ -218,18 +222,33 @@ private class AnyArgsConverter : ArgsConverter<Any> {
|
||||
else -> null
|
||||
}
|
||||
|
||||
if (value::class.isSubclassOf(parameter.type.jvmErasure)) return ArgsConverter.Result.Success(value)
|
||||
fun evaluateValue(arg: Any): Any? {
|
||||
if (arg::class.isSubclassOf(parameter.type.jvmErasure)) return arg
|
||||
return convertPrimitivesArray(parameter.type, arg)
|
||||
}
|
||||
|
||||
return convertPrimitivesArray(parameter.type, value)?.let { ArgsConverter.Result.Success(it) }
|
||||
?: ArgsConverter.Result.Failure
|
||||
evaluateValue(value)?.let { return ArgsConverter.Result.Success(it) }
|
||||
|
||||
// Handle the scenario where [arg::class] is an Array<Any>
|
||||
// but it's values could all still be valid
|
||||
val parameterKClass = parameter.type.classifier as? KClass<*>
|
||||
val arrayComponentType = parameterKClass?.java?.takeIf { it.isArray}?.componentType?.kotlin
|
||||
|
||||
if (value is Array<*> && arrayComponentType != null) {
|
||||
// TODO: Idea! Maybe we should check if the values in the array are compatible with [arrayComponentType]
|
||||
// if they aren't perhaps we should fail silently
|
||||
convertAnyArray(arrayComponentType, value.asSequence())?.let(::evaluateValue)?.let { return ArgsConverter.Result.Success(it) }
|
||||
}
|
||||
|
||||
return ArgsConverter.Result.Failure
|
||||
}
|
||||
|
||||
override fun tryConvertVararg(
|
||||
parameter: KParameter, firstArg: NamedArgument<Any>, restArgsIt: Iterator<NamedArgument<Any>>
|
||||
parameter: KParameter, firstArg: NamedArgument<Any>, restArgs: Sequence<NamedArgument<Any>>
|
||||
): ArgsConverter.Result {
|
||||
val parameterType = parameter.type
|
||||
if (parameterType.jvmErasure.java.isArray) {
|
||||
val argsSequence = sequenceOf(firstArg.value) + restArgsIt.asSequence().map { it.value }
|
||||
val argsSequence = sequenceOf(firstArg.value) + restArgs.map { it.value }
|
||||
val arrayElementType = parameterType.arguments.firstOrNull()?.type
|
||||
val arrayArgCandidate = convertAnyArray(arrayElementType?.classifier, argsSequence)
|
||||
if (arrayArgCandidate != null)
|
||||
@@ -242,7 +261,7 @@ private class AnyArgsConverter : ArgsConverter<Any> {
|
||||
override fun tryConvertTail(
|
||||
parameter: KParameter,
|
||||
firstArg: NamedArgument<Any>,
|
||||
restArgsIt: Iterator<NamedArgument<Any>>
|
||||
restArgs: Sequence<NamedArgument<Any>>
|
||||
): ArgsConverter.Result =
|
||||
tryConvertSingle(parameter, firstArg)
|
||||
}
|
||||
@@ -266,3 +285,38 @@ private fun <T> convertAnyArrayImpl(classifier: KClassifier?, args: Sequence<T?>
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
/*
|
||||
An iterator that allows us to read the next value without consuming it.
|
||||
*/
|
||||
private class LookAheadIterator<T>(private val iterator: Iterator<T>) : Iterator<T> {
|
||||
private var currentLookAhead: T? = null
|
||||
|
||||
override fun hasNext(): Boolean {
|
||||
return currentLookAhead != null || iterator.hasNext()
|
||||
}
|
||||
|
||||
override fun next(): T {
|
||||
currentLookAhead?.let { value ->
|
||||
currentLookAhead = null
|
||||
return value
|
||||
}
|
||||
|
||||
return iterator.next()
|
||||
}
|
||||
|
||||
fun nextWithoutConsuming(): T {
|
||||
return currentLookAhead ?: iterator.next().also { currentLookAhead = it }
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Will return a sequence with the values of the iterator until the predicate evaluates to true.
|
||||
*/
|
||||
private fun <T> LookAheadIterator<T>.sequenceUntil(predicate: (T) -> Boolean): Sequence<T> = sequence {
|
||||
while (hasNext()) {
|
||||
if (predicate(nextWithoutConsuming()))
|
||||
break
|
||||
yield(next())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -229,14 +229,19 @@ class K2JsIrCompiler : CLICompiler<K2JSCompilerArguments>() {
|
||||
mainArguments = mainCallArguments,
|
||||
generateFullJs = !arguments.irDce,
|
||||
generateDceJs = arguments.irDce,
|
||||
dceDriven = arguments.irDceDriven
|
||||
dceDriven = arguments.irDceDriven,
|
||||
multiModule = arguments.irPerModule,
|
||||
relativeRequirePath = true
|
||||
)
|
||||
} catch (e: JsIrCompilationError) {
|
||||
return COMPILATION_ERROR
|
||||
}
|
||||
|
||||
val jsCode = if (arguments.irDce && !arguments.irDceDriven) compiledModule.dceJsCode!! else compiledModule.jsCode!!
|
||||
outputFile.writeText(jsCode)
|
||||
outputFile.writeText(jsCode.mainModule)
|
||||
jsCode.dependencies.forEach { (name, content) ->
|
||||
outputFile.resolveSibling("$name.js").writeText(content)
|
||||
}
|
||||
if (arguments.generateDts) {
|
||||
val dtsFile = outputFile.withReplacedExtensionOrNull(outputFile.extension, "d.ts")!!
|
||||
dtsFile.writeText(compiledModule.tsDefinitions ?: error("No ts definitions"))
|
||||
@@ -322,6 +327,7 @@ class K2JsIrCompiler : CLICompiler<K2JSCompilerArguments>() {
|
||||
}
|
||||
|
||||
configuration.put(JSConfigurationKeys.PRINT_REACHABILITY_INFO, arguments.irDcePrintReachabilityInfo)
|
||||
configuration.put(JSConfigurationKeys.DISABLE_FAKE_OVERRIDE_VALIDATOR, arguments.disableFakeOverrideValidator)
|
||||
}
|
||||
|
||||
override fun executableScriptFileName(): String {
|
||||
|
||||
@@ -26,6 +26,7 @@ fun <A : CommonCompilerArguments> CompilerConfiguration.setupCommonArguments(
|
||||
put(CommonConfigurationKeys.EXPECT_ACTUAL_LINKER, arguments.expectActualLinker)
|
||||
putIfNotNull(CLIConfigurationKeys.INTELLIJ_PLUGIN_ROOT, arguments.intellijPluginRoot)
|
||||
put(CommonConfigurationKeys.REPORT_OUTPUT_FILES, arguments.reportOutputFiles)
|
||||
put(CommonConfigurationKeys.DESERIALIZE_FAKE_OVERRIDES, arguments.deserializeFakeOverrides)
|
||||
|
||||
val metadataVersionString = arguments.metadataVersion
|
||||
if (metadataVersionString != null) {
|
||||
|
||||
@@ -4,147 +4,52 @@
|
||||
*/
|
||||
package org.jetbrains.kotlin.cli.jvm.compiler;
|
||||
|
||||
import com.intellij.DynamicBundle;
|
||||
import com.intellij.codeInsight.ContainerProvider;
|
||||
import com.intellij.codeInsight.JavaContainerProvider;
|
||||
import com.intellij.codeInsight.folding.JavaCodeFoldingSettings;
|
||||
import com.intellij.codeInsight.folding.impl.JavaCodeFoldingSettingsBase;
|
||||
import com.intellij.codeInsight.folding.impl.JavaFoldingBuilderBase;
|
||||
import com.intellij.codeInsight.runner.JavaMainMethodProvider;
|
||||
import com.intellij.core.CoreApplicationEnvironment;
|
||||
import com.intellij.core.CoreJavaDirectoryService;
|
||||
import com.intellij.core.CorePsiPackageImplementationHelper;
|
||||
import com.intellij.ide.highlighter.ArchiveFileType;
|
||||
import com.intellij.ide.highlighter.JavaClassFileType;
|
||||
import com.intellij.ide.highlighter.JavaFileType;
|
||||
import com.intellij.lang.LanguageASTFactory;
|
||||
import com.intellij.core.JavaCoreApplicationEnvironment;
|
||||
import com.intellij.lang.MetaLanguage;
|
||||
import com.intellij.lang.folding.LanguageFolding;
|
||||
import com.intellij.lang.java.JavaLanguage;
|
||||
import com.intellij.lang.java.JavaParserDefinition;
|
||||
import com.intellij.navigation.ItemPresentationProviders;
|
||||
import com.intellij.openapi.Disposable;
|
||||
import com.intellij.openapi.extensions.Extensions;
|
||||
import com.intellij.openapi.extensions.ExtensionsArea;
|
||||
import com.intellij.openapi.fileTypes.FileTypeExtensionPoint;
|
||||
import com.intellij.openapi.fileTypes.PlainTextFileType;
|
||||
import com.intellij.openapi.fileTypes.PlainTextLanguage;
|
||||
import com.intellij.openapi.fileTypes.PlainTextParserDefinition;
|
||||
import com.intellij.openapi.projectRoots.JavaVersionService;
|
||||
import com.intellij.openapi.vfs.VirtualFileSystem;
|
||||
import com.intellij.psi.*;
|
||||
import com.intellij.psi.FileContextProvider;
|
||||
import com.intellij.psi.augment.PsiAugmentProvider;
|
||||
import com.intellij.psi.augment.TypeAnnotationModifier;
|
||||
import com.intellij.psi.compiled.ClassFileDecompilers;
|
||||
import com.intellij.psi.impl.LanguageConstantExpressionEvaluator;
|
||||
import com.intellij.psi.impl.PsiExpressionEvaluator;
|
||||
import com.intellij.psi.impl.PsiSubstitutorFactoryImpl;
|
||||
import com.intellij.psi.impl.compiled.ClassFileStubBuilder;
|
||||
import com.intellij.psi.impl.file.PsiPackageImplementationHelper;
|
||||
import com.intellij.psi.impl.search.MethodSuperSearcher;
|
||||
import com.intellij.psi.impl.source.tree.JavaASTFactory;
|
||||
import com.intellij.psi.impl.source.tree.PlainTextASTFactory;
|
||||
import com.intellij.psi.meta.MetaDataContributor;
|
||||
import com.intellij.psi.presentation.java.*;
|
||||
import com.intellij.psi.search.searches.SuperMethodsSearch;
|
||||
import com.intellij.psi.stubs.BinaryFileStubBuilders;
|
||||
import com.intellij.util.QueryExecutor;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.cli.jvm.modules.CoreJrtFileSystem;
|
||||
|
||||
/**
|
||||
* adapted from com.intellij.core.JavaCoreApplicationEnvironment
|
||||
* TODO: initiate removal original from com.intellij.core since it seems that there are no usages left
|
||||
*/
|
||||
public class KotlinCoreApplicationEnvironment extends CoreApplicationEnvironment {
|
||||
public class KotlinCoreApplicationEnvironment extends JavaCoreApplicationEnvironment {
|
||||
public static KotlinCoreApplicationEnvironment create(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
KotlinCoreApplicationEnvironment environment = new KotlinCoreApplicationEnvironment(parentDisposable, unitTestMode);
|
||||
registerExtensionPoints();
|
||||
return environment;
|
||||
}
|
||||
|
||||
public static KotlinCoreApplicationEnvironment create(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
return new KotlinCoreApplicationEnvironment(parentDisposable, unitTestMode);
|
||||
}
|
||||
private KotlinCoreApplicationEnvironment(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
super(parentDisposable, unitTestMode);
|
||||
}
|
||||
|
||||
private KotlinCoreApplicationEnvironment(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
super(parentDisposable, unitTestMode);
|
||||
private static void registerExtensionPoints() {
|
||||
registerApplicationExtensionPoint(DynamicBundle.LanguageBundleEP.EP_NAME, DynamicBundle.LanguageBundleEP.class);
|
||||
registerApplicationExtensionPoint(FileContextProvider.EP_NAME, FileContextProvider.class);
|
||||
|
||||
registerExtensionPoints();
|
||||
registerApplicationExtensionPoint(MetaDataContributor.EP_NAME, MetaDataContributor.class);
|
||||
registerApplicationExtensionPoint(PsiAugmentProvider.EP_NAME, PsiAugmentProvider.class);
|
||||
registerApplicationExtensionPoint(JavaMainMethodProvider.EP_NAME, JavaMainMethodProvider.class);
|
||||
|
||||
registerExtensions();
|
||||
}
|
||||
registerApplicationExtensionPoint(ContainerProvider.EP_NAME, ContainerProvider.class);
|
||||
registerApplicationExtensionPoint(ClassFileDecompilers.EP_NAME, ClassFileDecompilers.Decompiler.class);
|
||||
|
||||
private void registerExtensionPoints() {
|
||||
ExtensionsArea area = Extensions.getRootArea();
|
||||
registerApplicationExtensionPoint(MetaLanguage.EP_NAME, MetaLanguage.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, BinaryFileStubBuilders.EP_NAME, FileTypeExtensionPoint.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, FileContextProvider.EP_NAME, FileContextProvider.class);
|
||||
IdeaExtensionPoints.INSTANCE.registerVersionSpecificAppExtensionPoints(Extensions.getRootArea());
|
||||
}
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, MetaDataContributor.EP_NAME, MetaDataContributor.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, PsiAugmentProvider.EP_NAME, PsiAugmentProvider.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, JavaMainMethodProvider.EP_NAME, JavaMainMethodProvider.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, ContainerProvider.EP_NAME, ContainerProvider.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, ClassFileDecompilers.EP_NAME, ClassFileDecompilers.Decompiler.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, TypeAnnotationModifier.EP_NAME, TypeAnnotationModifier.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, MetaLanguage.EP_NAME, MetaLanguage.class);
|
||||
|
||||
IdeaExtensionPoints.INSTANCE.registerVersionSpecificAppExtensionPoints(area);
|
||||
}
|
||||
|
||||
private void registerExtensions() {
|
||||
registerFileType(JavaClassFileType.INSTANCE, "class");
|
||||
registerFileType(JavaFileType.INSTANCE, "java");
|
||||
registerFileType(ArchiveFileType.INSTANCE, "jar;zip");
|
||||
registerFileType(PlainTextFileType.INSTANCE, "txt;sh;bat;cmd;policy;log;cgi;MF;jad;jam;htaccess");
|
||||
|
||||
addExplicitExtension(LanguageASTFactory.INSTANCE, PlainTextLanguage.INSTANCE, new PlainTextASTFactory());
|
||||
registerParserDefinition(new PlainTextParserDefinition());
|
||||
|
||||
addExplicitExtension(FileTypeFileViewProviders.INSTANCE, JavaClassFileType.INSTANCE, new ClassFileViewProviderFactory());
|
||||
addExplicitExtension(BinaryFileStubBuilders.INSTANCE, JavaClassFileType.INSTANCE, new ClassFileStubBuilder());
|
||||
|
||||
addExplicitExtension(LanguageASTFactory.INSTANCE, JavaLanguage.INSTANCE, new JavaASTFactory());
|
||||
registerParserDefinition(new JavaParserDefinition());
|
||||
addExplicitExtension(LanguageConstantExpressionEvaluator.INSTANCE, JavaLanguage.INSTANCE, new PsiExpressionEvaluator());
|
||||
|
||||
addExtension(ContainerProvider.EP_NAME, new JavaContainerProvider());
|
||||
|
||||
myApplication.registerService(PsiPackageImplementationHelper.class, new CorePsiPackageImplementationHelper());
|
||||
myApplication.registerService(PsiSubstitutorFactory.class, new PsiSubstitutorFactoryImpl());
|
||||
|
||||
myApplication.registerService(JavaDirectoryService.class, createJavaDirectoryService());
|
||||
myApplication.registerService(JavaVersionService.class, new JavaVersionService());
|
||||
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiPackage.class, new PackagePresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiClass.class, new ClassPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiMethod.class, new MethodPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiField.class, new FieldPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiLocalVariable.class, new VariablePresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiParameter.class, new VariablePresentationProvider());
|
||||
|
||||
registerApplicationService(JavaCodeFoldingSettings.class, new JavaCodeFoldingSettingsBase());
|
||||
addExplicitExtension(LanguageFolding.INSTANCE, JavaLanguage.INSTANCE, new JavaFoldingBuilderBase() {
|
||||
@Override
|
||||
protected boolean shouldShowExplicitLambdaType(@NotNull PsiAnonymousClass anonymousClass, @NotNull PsiNewExpression expression) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isBelowRightMargin(@NotNull PsiFile file, int lineLength) {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
registerApplicationExtensionPoint(SuperMethodsSearch.EP_NAME, QueryExecutor.class);
|
||||
addExtension(SuperMethodsSearch.EP_NAME, new MethodSuperSearcher());
|
||||
}
|
||||
|
||||
// overridden in upsource
|
||||
protected CoreJavaDirectoryService createJavaDirectoryService() {
|
||||
return new CoreJavaDirectoryService();
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
protected VirtualFileSystem createJrtFileSystem() {
|
||||
return new CoreJrtFileSystem();
|
||||
}
|
||||
@Nullable
|
||||
@Override
|
||||
protected VirtualFileSystem createJrtFileSystem() {
|
||||
return new CoreJrtFileSystem();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,150 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
package org.jetbrains.kotlin.cli.jvm.compiler;
|
||||
|
||||
import com.intellij.codeInsight.ContainerProvider;
|
||||
import com.intellij.codeInsight.JavaContainerProvider;
|
||||
import com.intellij.codeInsight.folding.JavaCodeFoldingSettings;
|
||||
import com.intellij.codeInsight.folding.impl.JavaCodeFoldingSettingsBase;
|
||||
import com.intellij.codeInsight.folding.impl.JavaFoldingBuilderBase;
|
||||
import com.intellij.codeInsight.runner.JavaMainMethodProvider;
|
||||
import com.intellij.core.CoreApplicationEnvironment;
|
||||
import com.intellij.core.CoreJavaDirectoryService;
|
||||
import com.intellij.core.CorePsiPackageImplementationHelper;
|
||||
import com.intellij.ide.highlighter.ArchiveFileType;
|
||||
import com.intellij.ide.highlighter.JavaClassFileType;
|
||||
import com.intellij.ide.highlighter.JavaFileType;
|
||||
import com.intellij.lang.LanguageASTFactory;
|
||||
import com.intellij.lang.MetaLanguage;
|
||||
import com.intellij.lang.folding.LanguageFolding;
|
||||
import com.intellij.lang.java.JavaLanguage;
|
||||
import com.intellij.lang.java.JavaParserDefinition;
|
||||
import com.intellij.navigation.ItemPresentationProviders;
|
||||
import com.intellij.openapi.Disposable;
|
||||
import com.intellij.openapi.extensions.Extensions;
|
||||
import com.intellij.openapi.extensions.ExtensionsArea;
|
||||
import com.intellij.openapi.fileTypes.FileTypeExtensionPoint;
|
||||
import com.intellij.openapi.fileTypes.PlainTextFileType;
|
||||
import com.intellij.openapi.fileTypes.PlainTextLanguage;
|
||||
import com.intellij.openapi.fileTypes.PlainTextParserDefinition;
|
||||
import com.intellij.openapi.projectRoots.JavaVersionService;
|
||||
import com.intellij.openapi.vfs.VirtualFileSystem;
|
||||
import com.intellij.psi.*;
|
||||
import com.intellij.psi.augment.PsiAugmentProvider;
|
||||
import com.intellij.psi.augment.TypeAnnotationModifier;
|
||||
import com.intellij.psi.compiled.ClassFileDecompilers;
|
||||
import com.intellij.psi.impl.LanguageConstantExpressionEvaluator;
|
||||
import com.intellij.psi.impl.PsiExpressionEvaluator;
|
||||
import com.intellij.psi.impl.PsiSubstitutorFactoryImpl;
|
||||
import com.intellij.psi.impl.compiled.ClassFileStubBuilder;
|
||||
import com.intellij.psi.impl.file.PsiPackageImplementationHelper;
|
||||
import com.intellij.psi.impl.search.MethodSuperSearcher;
|
||||
import com.intellij.psi.impl.source.tree.JavaASTFactory;
|
||||
import com.intellij.psi.impl.source.tree.PlainTextASTFactory;
|
||||
import com.intellij.psi.meta.MetaDataContributor;
|
||||
import com.intellij.psi.presentation.java.*;
|
||||
import com.intellij.psi.search.searches.SuperMethodsSearch;
|
||||
import com.intellij.psi.stubs.BinaryFileStubBuilders;
|
||||
import com.intellij.util.QueryExecutor;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.cli.jvm.modules.CoreJrtFileSystem;
|
||||
|
||||
/**
|
||||
* adapted from com.intellij.core.JavaCoreApplicationEnvironment
|
||||
* TODO: initiate removal original from com.intellij.core since it seems that there are no usages left
|
||||
*/
|
||||
public class KotlinCoreApplicationEnvironment extends CoreApplicationEnvironment {
|
||||
|
||||
public static KotlinCoreApplicationEnvironment create(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
return new KotlinCoreApplicationEnvironment(parentDisposable, unitTestMode);
|
||||
}
|
||||
|
||||
private KotlinCoreApplicationEnvironment(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
super(parentDisposable, unitTestMode);
|
||||
|
||||
registerExtensionPoints();
|
||||
|
||||
registerExtensions();
|
||||
}
|
||||
|
||||
private void registerExtensionPoints() {
|
||||
ExtensionsArea area = Extensions.getRootArea();
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, BinaryFileStubBuilders.EP_NAME, FileTypeExtensionPoint.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, FileContextProvider.EP_NAME, FileContextProvider.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, MetaDataContributor.EP_NAME, MetaDataContributor.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, PsiAugmentProvider.EP_NAME, PsiAugmentProvider.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, JavaMainMethodProvider.EP_NAME, JavaMainMethodProvider.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, ContainerProvider.EP_NAME, ContainerProvider.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, ClassFileDecompilers.EP_NAME, ClassFileDecompilers.Decompiler.class);
|
||||
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, TypeAnnotationModifier.EP_NAME, TypeAnnotationModifier.class);
|
||||
CoreApplicationEnvironment.registerExtensionPoint(area, MetaLanguage.EP_NAME, MetaLanguage.class);
|
||||
|
||||
IdeaExtensionPoints.INSTANCE.registerVersionSpecificAppExtensionPoints(area);
|
||||
}
|
||||
|
||||
private void registerExtensions() {
|
||||
registerFileType(JavaClassFileType.INSTANCE, "class");
|
||||
registerFileType(JavaFileType.INSTANCE, "java");
|
||||
registerFileType(ArchiveFileType.INSTANCE, "jar;zip");
|
||||
registerFileType(PlainTextFileType.INSTANCE, "txt;sh;bat;cmd;policy;log;cgi;MF;jad;jam;htaccess");
|
||||
|
||||
addExplicitExtension(LanguageASTFactory.INSTANCE, PlainTextLanguage.INSTANCE, new PlainTextASTFactory());
|
||||
registerParserDefinition(new PlainTextParserDefinition());
|
||||
|
||||
addExplicitExtension(FileTypeFileViewProviders.INSTANCE, JavaClassFileType.INSTANCE, new ClassFileViewProviderFactory());
|
||||
addExplicitExtension(BinaryFileStubBuilders.INSTANCE, JavaClassFileType.INSTANCE, new ClassFileStubBuilder());
|
||||
|
||||
addExplicitExtension(LanguageASTFactory.INSTANCE, JavaLanguage.INSTANCE, new JavaASTFactory());
|
||||
registerParserDefinition(new JavaParserDefinition());
|
||||
addExplicitExtension(LanguageConstantExpressionEvaluator.INSTANCE, JavaLanguage.INSTANCE, new PsiExpressionEvaluator());
|
||||
|
||||
addExtension(ContainerProvider.EP_NAME, new JavaContainerProvider());
|
||||
|
||||
myApplication.registerService(PsiPackageImplementationHelper.class, new CorePsiPackageImplementationHelper());
|
||||
myApplication.registerService(PsiSubstitutorFactory.class, new PsiSubstitutorFactoryImpl());
|
||||
|
||||
myApplication.registerService(JavaDirectoryService.class, createJavaDirectoryService());
|
||||
myApplication.registerService(JavaVersionService.class, new JavaVersionService());
|
||||
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiPackage.class, new PackagePresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiClass.class, new ClassPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiMethod.class, new MethodPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiField.class, new FieldPresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiLocalVariable.class, new VariablePresentationProvider());
|
||||
addExplicitExtension(ItemPresentationProviders.INSTANCE, PsiParameter.class, new VariablePresentationProvider());
|
||||
|
||||
registerApplicationService(JavaCodeFoldingSettings.class, new JavaCodeFoldingSettingsBase());
|
||||
addExplicitExtension(LanguageFolding.INSTANCE, JavaLanguage.INSTANCE, new JavaFoldingBuilderBase() {
|
||||
@Override
|
||||
protected boolean shouldShowExplicitLambdaType(@NotNull PsiAnonymousClass anonymousClass, @NotNull PsiNewExpression expression) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isBelowRightMargin(@NotNull PsiFile file, int lineLength) {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
registerApplicationExtensionPoint(SuperMethodsSearch.EP_NAME, QueryExecutor.class);
|
||||
addExtension(SuperMethodsSearch.EP_NAME, new MethodSuperSearcher());
|
||||
}
|
||||
|
||||
// overridden in upsource
|
||||
protected CoreJavaDirectoryService createJavaDirectoryService() {
|
||||
return new CoreJavaDirectoryService();
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
protected VirtualFileSystem createJrtFileSystem() {
|
||||
return new CoreJrtFileSystem();
|
||||
}
|
||||
}
|
||||
@@ -1,55 +0,0 @@
|
||||
/*
|
||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
package org.jetbrains.kotlin.cli.jvm.compiler;
|
||||
|
||||
import com.intellij.DynamicBundle;
|
||||
import com.intellij.codeInsight.ContainerProvider;
|
||||
import com.intellij.codeInsight.runner.JavaMainMethodProvider;
|
||||
import com.intellij.core.JavaCoreApplicationEnvironment;
|
||||
import com.intellij.lang.MetaLanguage;
|
||||
import com.intellij.openapi.Disposable;
|
||||
import com.intellij.openapi.extensions.Extensions;
|
||||
import com.intellij.openapi.vfs.VirtualFileSystem;
|
||||
import com.intellij.psi.FileContextProvider;
|
||||
import com.intellij.psi.augment.PsiAugmentProvider;
|
||||
import com.intellij.psi.compiled.ClassFileDecompilers;
|
||||
import com.intellij.psi.meta.MetaDataContributor;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.cli.jvm.modules.CoreJrtFileSystem;
|
||||
|
||||
public class KotlinCoreApplicationEnvironment extends JavaCoreApplicationEnvironment {
|
||||
public static KotlinCoreApplicationEnvironment create(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
KotlinCoreApplicationEnvironment environment = new KotlinCoreApplicationEnvironment(parentDisposable, unitTestMode);
|
||||
registerExtensionPoints();
|
||||
return environment;
|
||||
}
|
||||
|
||||
private KotlinCoreApplicationEnvironment(@NotNull Disposable parentDisposable, boolean unitTestMode) {
|
||||
super(parentDisposable, unitTestMode);
|
||||
}
|
||||
|
||||
private static void registerExtensionPoints() {
|
||||
registerApplicationExtensionPoint(DynamicBundle.LanguageBundleEP.EP_NAME, DynamicBundle.LanguageBundleEP.class);
|
||||
registerApplicationExtensionPoint(FileContextProvider.EP_NAME, FileContextProvider.class);
|
||||
|
||||
registerApplicationExtensionPoint(MetaDataContributor.EP_NAME, MetaDataContributor.class);
|
||||
registerApplicationExtensionPoint(PsiAugmentProvider.EP_NAME, PsiAugmentProvider.class);
|
||||
registerApplicationExtensionPoint(JavaMainMethodProvider.EP_NAME, JavaMainMethodProvider.class);
|
||||
|
||||
registerApplicationExtensionPoint(ContainerProvider.EP_NAME, ContainerProvider.class);
|
||||
registerApplicationExtensionPoint(ClassFileDecompilers.EP_NAME, ClassFileDecompilers.Decompiler.class);
|
||||
|
||||
registerApplicationExtensionPoint(MetaLanguage.EP_NAME, MetaLanguage.class);
|
||||
|
||||
IdeaExtensionPoints.INSTANCE.registerVersionSpecificAppExtensionPoints(Extensions.getRootArea());
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
protected VirtualFileSystem createJrtFileSystem() {
|
||||
return new CoreJrtFileSystem();
|
||||
}
|
||||
}
|
||||
@@ -22,6 +22,7 @@ import com.intellij.psi.*
|
||||
|
||||
class MockExternalAnnotationsManager : ExternalAnnotationsManager() {
|
||||
override fun chooseAnnotationsPlace(element: PsiElement): AnnotationPlace = AnnotationPlace.NOWHERE
|
||||
override fun chooseAnnotationsPlaceNoUi(element: PsiElement): AnnotationPlace = AnnotationPlace.NOWHERE
|
||||
|
||||
override fun isExternalAnnotationWritable(listOwner: PsiModifierListOwner, annotationFQN: String): Boolean = false
|
||||
override fun isExternalAnnotation(annotation: PsiAnnotation): Boolean = false
|
||||
|
||||
@@ -22,7 +22,6 @@ import com.intellij.psi.*
|
||||
|
||||
class MockExternalAnnotationsManager : ExternalAnnotationsManager() {
|
||||
override fun chooseAnnotationsPlace(element: PsiElement): AnnotationPlace = AnnotationPlace.NOWHERE
|
||||
override fun chooseAnnotationsPlaceNoUi(element: PsiElement): AnnotationPlace = AnnotationPlace.NOWHERE
|
||||
|
||||
override fun isExternalAnnotationWritable(listOwner: PsiModifierListOwner, annotationFQN: String): Boolean = false
|
||||
override fun isExternalAnnotation(annotation: PsiAnnotation): Boolean = false
|
||||
@@ -66,6 +66,7 @@ import org.jetbrains.kotlin.platform.TargetPlatform
|
||||
import org.jetbrains.kotlin.platform.jvm.JvmPlatforms
|
||||
import org.jetbrains.kotlin.psi.KtFile
|
||||
import org.jetbrains.kotlin.resolve.*
|
||||
import org.jetbrains.kotlin.resolve.calls.tower.ImplicitsExtensionsResolutionFilter
|
||||
import org.jetbrains.kotlin.resolve.jvm.JavaDescriptorResolver
|
||||
import org.jetbrains.kotlin.resolve.jvm.extensions.AnalysisHandlerExtension
|
||||
import org.jetbrains.kotlin.resolve.jvm.extensions.PackageFragmentProviderExtension
|
||||
@@ -135,7 +136,8 @@ object TopDownAnalyzerFacadeForJVM {
|
||||
declarationProviderFactory: (StorageManager, Collection<KtFile>) -> DeclarationProviderFactory,
|
||||
targetEnvironment: TargetEnvironment = CompilerEnvironment,
|
||||
sourceModuleSearchScope: GlobalSearchScope = newModuleSearchScope(project, files),
|
||||
klibList: List<KotlinLibrary> = emptyList()
|
||||
klibList: List<KotlinLibrary> = emptyList(),
|
||||
implicitsResolutionFilter: ImplicitsExtensionsResolutionFilter? = null
|
||||
): ComponentProvider {
|
||||
val jvmTarget = configuration.get(JVMConfigurationKeys.JVM_TARGET, JvmTarget.DEFAULT)
|
||||
val languageVersionSettings = configuration.languageVersionSettings
|
||||
@@ -186,7 +188,8 @@ object TopDownAnalyzerFacadeForJVM {
|
||||
targetEnvironment, lookupTracker, expectActualTracker,
|
||||
packagePartProvider(dependencyScope), languageVersionSettings,
|
||||
useBuiltInsProvider = true,
|
||||
configureJavaClassFinder = configureJavaClassFinder
|
||||
configureJavaClassFinder = configureJavaClassFinder,
|
||||
implicitsResolutionFilter = implicitsResolutionFilter
|
||||
)
|
||||
|
||||
moduleClassResolver.compiledCodeResolver = dependenciesContainer.get()
|
||||
@@ -220,7 +223,8 @@ object TopDownAnalyzerFacadeForJVM {
|
||||
partProvider, languageVersionSettings,
|
||||
useBuiltInsProvider = true,
|
||||
configureJavaClassFinder = configureJavaClassFinder,
|
||||
javaClassTracker = configuration[JVMConfigurationKeys.JAVA_CLASSES_TRACKER]
|
||||
javaClassTracker = configuration[JVMConfigurationKeys.JAVA_CLASSES_TRACKER],
|
||||
implicitsResolutionFilter = implicitsResolutionFilter
|
||||
).apply {
|
||||
initJvmBuiltInsForTopDownAnalysis()
|
||||
(partProvider as? IncrementalPackagePartProvider)?.deserializationConfiguration = get()
|
||||
|
||||
@@ -6,4 +6,10 @@
|
||||
package org.jetbrains.kotlin.cli.jvm.compiler
|
||||
|
||||
fun setupIdeaStandaloneExecution() {
|
||||
System.getProperties().setProperty("idea.plugins.compatible.build", "201.6668.13")
|
||||
System.getProperties().setProperty("project.structure.add.tools.jar.to.new.jdk", "false")
|
||||
System.getProperties().setProperty("psi.track.invalidation", "true")
|
||||
System.getProperties().setProperty("psi.incremental.reparse.depth.limit", "1000")
|
||||
System.getProperties().setProperty("ide.hide.excluded.files", "false")
|
||||
System.getProperties().setProperty("ast.loading.filter", "false")
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
/*
|
||||
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||
*/
|
||||
|
||||
package org.jetbrains.kotlin.cli.jvm.compiler
|
||||
|
||||
fun setupIdeaStandaloneExecution() {
|
||||
}
|
||||
@@ -12,4 +12,5 @@ fun setupIdeaStandaloneExecution() {
|
||||
System.getProperties().setProperty("psi.incremental.reparse.depth.limit", "1000")
|
||||
System.getProperties().setProperty("ide.hide.excluded.files", "false")
|
||||
System.getProperties().setProperty("ast.loading.filter", "false")
|
||||
System.getProperties().setProperty("idea.ignore.disabled.plugins", "true")
|
||||
}
|
||||
@@ -8,9 +8,11 @@ package org.jetbrains.kotlin.cli.jvm.compiler
|
||||
import com.intellij.core.CoreApplicationEnvironment
|
||||
import com.intellij.openapi.extensions.ExtensionsArea
|
||||
import java.io.File
|
||||
import java.nio.file.FileSystems
|
||||
|
||||
// FIX ME WHEN BUNCH 193 REMOVED
|
||||
fun registerExtensionPointAndExtensionsEx(pluginFile: File, fileName: String, area: ExtensionsArea) {
|
||||
val pluginRoot = FileSystems.getDefault().getPath(pluginFile.path)
|
||||
@Suppress("MissingRecentApi")
|
||||
CoreApplicationEnvironment.registerExtensionPointAndExtensions(pluginFile, fileName, area)
|
||||
CoreApplicationEnvironment.registerExtensionPointAndExtensions(pluginRoot, fileName, area)
|
||||
}
|
||||
@@ -8,11 +8,9 @@ package org.jetbrains.kotlin.cli.jvm.compiler
|
||||
import com.intellij.core.CoreApplicationEnvironment
|
||||
import com.intellij.openapi.extensions.ExtensionsArea
|
||||
import java.io.File
|
||||
import java.nio.file.FileSystems
|
||||
|
||||
// FIX ME WHEN BUNCH 193 REMOVED
|
||||
fun registerExtensionPointAndExtensionsEx(pluginFile: File, fileName: String, area: ExtensionsArea) {
|
||||
val pluginRoot = FileSystems.getDefault().getPath(pluginFile.path)
|
||||
@Suppress("MissingRecentApi")
|
||||
CoreApplicationEnvironment.registerExtensionPointAndExtensions(pluginRoot, fileName, area)
|
||||
CoreApplicationEnvironment.registerExtensionPointAndExtensions(pluginFile, fileName, area)
|
||||
}
|
||||
@@ -38,6 +38,17 @@ fun CompilerConfiguration.setupJvmSpecificArguments(arguments: K2JVMCompilerArgu
|
||||
}
|
||||
}
|
||||
|
||||
val jvmTarget = get(JVMConfigurationKeys.JVM_TARGET) ?: JvmTarget.DEFAULT
|
||||
if (jvmTarget.bytecodeVersion < JvmTarget.JVM_1_8.bytecodeVersion) {
|
||||
val jvmDefaultMode = languageVersionSettings.getFlag(JvmAnalysisFlags.jvmDefaultMode)
|
||||
if (jvmDefaultMode.forAllMethodsWithBody) {
|
||||
messageCollector.report(
|
||||
ERROR,
|
||||
"'-Xjvm-default=${jvmDefaultMode.description}' is only supported since JVM target 1.8. Recompile with '-jvm-target 1.8'"
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
addAll(JVMConfigurationKeys.ADDITIONAL_JAVA_MODULES, arguments.additionalJavaModules?.asList())
|
||||
}
|
||||
|
||||
@@ -198,6 +209,7 @@ fun CompilerConfiguration.configureAdvancedJvmOptions(arguments: K2JVMCompilerAr
|
||||
|
||||
put(CLIConfigurationKeys.ALLOW_KOTLIN_PACKAGE, arguments.allowKotlinPackage)
|
||||
put(JVMConfigurationKeys.USE_SINGLE_MODULE, arguments.singleModule)
|
||||
put(JVMConfigurationKeys.USE_OLD_SPILLED_VAR_TYPE_ANALYSIS, arguments.useOldSpilledVarTypeAnalysis)
|
||||
|
||||
arguments.declarationsOutputPath?.let { put(JVMConfigurationKeys.DECLARATIONS_JSON_PATH, it) }
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ public class KotlinCompilerVersion {
|
||||
// Binaries produced by this compiler with that language version (or any future language version) are going to be marked
|
||||
// as "pre-release" and will not be loaded by release versions of the compiler.
|
||||
// Change this value before and after every major release
|
||||
private static final boolean IS_PRE_RELEASE = true;
|
||||
private static final boolean IS_PRE_RELEASE = false;
|
||||
|
||||
public static final String TEST_IS_PRE_RELEASE_SYSTEM_PROPERTY = "kotlin.test.is.pre.release";
|
||||
|
||||
|
||||
@@ -122,4 +122,7 @@ public class JVMConfigurationKeys {
|
||||
|
||||
public static final CompilerConfigurationKey<Boolean> NO_KOTLIN_NOTHING_VALUE_EXCEPTION =
|
||||
CompilerConfigurationKey.create("Do not use KotlinNothingValueException available since 1.4");
|
||||
|
||||
public static final CompilerConfigurationKey<Boolean> USE_OLD_SPILLED_VAR_TYPE_ANALYSIS =
|
||||
CompilerConfigurationKey.create("Use old, SourceInterpreter-based analysis for fields, used for spilled variables in coroutines");
|
||||
}
|
||||
|
||||
@@ -47,6 +47,9 @@ object CommonConfigurationKeys {
|
||||
|
||||
@JvmField
|
||||
val EXPECT_ACTUAL_LINKER = CompilerConfigurationKey.create<Boolean>("Experimental expext/actual linker")
|
||||
|
||||
@JvmField
|
||||
val DESERIALIZE_FAKE_OVERRIDES = CompilerConfigurationKey.create<Boolean>("Deserialize fake overrides")
|
||||
}
|
||||
|
||||
var CompilerConfiguration.languageVersionSettings: LanguageVersionSettings
|
||||
|
||||
@@ -208,10 +208,10 @@ public final class Byte : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Byte>|, R
|
||||
public final const val MIN_VALUE: R|kotlin/Byte| = Byte(-128)
|
||||
public get(): R|kotlin/Byte|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(8)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(8)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(1)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(1)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Byte.Companion|
|
||||
@@ -279,7 +279,7 @@ public final class Char : R|kotlin/Comparable<kotlin/Char>|, R|java/io/Serializa
|
||||
public final const val MAX_SURROGATE: R|kotlin/Char| = Char(57343)
|
||||
public get(): R|kotlin/Char|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val MAX_VALUE: R|kotlin/Char| = Char(65535)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val MAX_VALUE: R|kotlin/Char| = Char(65535)
|
||||
public get(): R|kotlin/Char|
|
||||
|
||||
public final const val MIN_HIGH_SURROGATE: R|kotlin/Char| = Char(55296)
|
||||
@@ -291,13 +291,13 @@ public final class Char : R|kotlin/Comparable<kotlin/Char>|, R|java/io/Serializa
|
||||
public final const val MIN_SURROGATE: R|kotlin/Char| = Char(55296)
|
||||
public get(): R|kotlin/Char|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val MIN_VALUE: R|kotlin/Char| = Char(0)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val MIN_VALUE: R|kotlin/Char| = Char(0)
|
||||
public get(): R|kotlin/Char|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(16)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(16)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(2)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(2)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Char.Companion|
|
||||
@@ -358,6 +358,20 @@ public abstract interface Comparable<in T> : R|kotlin/Any| {
|
||||
|
||||
}
|
||||
|
||||
@R|kotlin/annotation/Target|() @R|kotlin/annotation/MustBeDocumented|() @R|kotlin/SinceKotlin|(version = String(1.4)) public final annotation class DeprecatedSinceKotlin : R|kotlin/Annotation| {
|
||||
public final val errorSince: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public final val hiddenSince: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public final val warningSince: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public constructor(warningSince: R|kotlin/String| = STUB, errorSince: R|kotlin/String| = STUB, hiddenSince: R|kotlin/String| = STUB): R|kotlin/DeprecatedSinceKotlin|
|
||||
|
||||
}
|
||||
|
||||
public final enum class DeprecationLevel : R|kotlin/Enum<kotlin/DeprecationLevel>| {
|
||||
private constructor(): R|kotlin/DeprecationLevel|
|
||||
|
||||
@@ -485,10 +499,10 @@ public final class Double : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Double>
|
||||
public final const val POSITIVE_INFINITY: R|kotlin/Double| = Double(Infinity)
|
||||
public get(): R|kotlin/Double|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BITS: R|kotlin/Int| = Int(64)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BITS: R|kotlin/Int| = Int(64)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(8)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(8)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Double.Companion|
|
||||
@@ -664,10 +678,10 @@ public final class Float : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Float>|,
|
||||
public final const val POSITIVE_INFINITY: R|kotlin/Float| = Float(Infinity)
|
||||
public get(): R|kotlin/Float|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BITS: R|kotlin/Int| = Int(32)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BITS: R|kotlin/Int| = Int(32)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(4)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.4)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(4)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Float.Companion|
|
||||
@@ -823,10 +837,10 @@ public final class Int : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Int>|, R|j
|
||||
public final const val MIN_VALUE: R|kotlin/Int| = Int(-2147483648)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(32)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(32)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(4)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(4)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Int.Companion|
|
||||
@@ -979,10 +993,10 @@ public final class Long : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Long>|, R
|
||||
public final const val MIN_VALUE: R|kotlin/Long| = Long(-9223372036854775808)
|
||||
public get(): R|kotlin/Long|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(64)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(64)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(8)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(8)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Long.Companion|
|
||||
@@ -1169,10 +1183,10 @@ public final class Short : R|kotlin/Number|, R|kotlin/Comparable<kotlin/Short>|,
|
||||
public final const val MIN_VALUE: R|kotlin/Short| = Short(-32768)
|
||||
public get(): R|kotlin/Short|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(16)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BITS: R|kotlin/Int| = Int(16)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(2)
|
||||
@PROPERTY:R|kotlin/SinceKotlin|(version = String(1.3)) public final const val SIZE_BYTES: R|kotlin/Int| = Int(2)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|kotlin/Short.Companion|
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
public open class AnnotatedMethod : R|kotlin/Any| {
|
||||
public open fun f(): R|kotlin/Unit|
|
||||
@R|kotlin/Deprecated|(message = String(Deprecated in Java)) public open fun f(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/AnnotatedMethod|
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
|
||||
}
|
||||
|
||||
@R|test/Anno|(klass = <getClass>(<getClass>(R|kotlin/String|)), klasses = <implicitArrayOf>(<getClass>(R|kotlin/Int|), <getClass>(R|kotlin/String|), <getClass>(R|kotlin/Float|)), sarKlass = <getClass>(<getClass>(R|kotlin/String|)), d2arKlass = <getClass>(<getClass>(R|kotlin/DoubleArray|))) public final class Klass : R|kotlin/Any| {
|
||||
@R|test/Anno|(klass = <getClass>(<getClass>(R|kotlin/String|)), klasses = <implicitArrayOf>(<getClass>(<getClass>(R|kotlin/Int|)), <getClass>(<getClass>(R|kotlin/String|)), <getClass>(<getClass>(R|kotlin/Float|))), sarKlass = <getClass>(<getClass>(R|kotlin/String|)), d2arKlass = <getClass>(<getClass>(R|kotlin/DoubleArray|))) public final class Klass : R|kotlin/Any| {
|
||||
public constructor(): R|test/Klass|
|
||||
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ public final annotation class EnumAnno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class EnumArgumentWithCustomToString : R|kotlin/Any| {
|
||||
public final fun annotated(): R|kotlin/Unit|
|
||||
@R|test/EnumAnno|(value = R|test/E.CAKE|()) @R|test/EnumArrayAnno|(value = <implicitArrayOf>(R|test/E.CAKE|(), R|test/E.CAKE|())) public final fun annotated(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/EnumArgumentWithCustomToString|
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public abstract interface T : R|kotlin/Any| {
|
||||
public abstract fun foo(): R|kotlin/Array<kotlin/Array<kotlin/Array<test/T>>>|
|
||||
@R|test/Anno|(s = String(foo)) public abstract fun foo(): R|kotlin/Array<kotlin/Array<kotlin/Array<test/T>>>|
|
||||
|
||||
public abstract val bar: R|kotlin/Array<kotlin/Array<kotlin/BooleanArray>>|
|
||||
public get(): R|kotlin/Array<kotlin/Array<kotlin/BooleanArray>>|
|
||||
|
||||
@@ -7,7 +7,7 @@ public final class Class : R|kotlin/Any| {
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
public final companion object Companion : R|kotlin/Any| {
|
||||
public final var property: R|kotlin/Int|
|
||||
@FIELD:R|test/Anno|() public final var property: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
|
||||
@@ -7,6 +7,6 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Constructor : R|kotlin/Any| {
|
||||
public constructor(): R|test/Constructor|
|
||||
@R|test/Anno|(value = String(string)) public constructor(): R|test/Constructor|
|
||||
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final val x: R|kotlin/Int|
|
||||
@PROPERTY:R|test/Anno|() public final val x: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
@@ -7,9 +7,9 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final fun foo(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = R|java/lang/annotation/ElementType.METHOD|()) public final fun foo(): R|kotlin/Unit|
|
||||
|
||||
public final var bar: R|kotlin/Int|
|
||||
@FIELD:R|test/Anno|(t = R|java/lang/annotation/ElementType.FIELD|()) public final var bar: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final fun foo(): R|kotlin/Unit|
|
||||
@R|test/Anno|() public final fun foo(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ public sealed class Sealed : R|kotlin/Any| {
|
||||
public final val z: R|test/Z|
|
||||
public get(): R|test/Z|
|
||||
|
||||
private constructor(z: R|test/Z|): R|test/Sealed|
|
||||
@R|test/Ann|() private constructor(@R|test/Ann|() z: R|test/Z|): R|test/Sealed|
|
||||
|
||||
public final class Derived : R|test/Sealed| {
|
||||
public constructor(z: R|test/Z|): R|test/Sealed.Derived|
|
||||
@@ -20,11 +20,11 @@ public final class Test : R|kotlin/Any| {
|
||||
public final val z: R|test/Z|
|
||||
public get(): R|test/Z|
|
||||
|
||||
public constructor(z: R|test/Z|, a: R|kotlin/Int|): R|test/Test|
|
||||
@R|test/Ann|() public constructor(z: R|test/Z|, @R|test/Ann|() a: R|kotlin/Int|): R|test/Test|
|
||||
|
||||
private constructor(z: R|test/Z|, s: R|kotlin/String|): R|test/Test|
|
||||
@R|test/Ann|() private constructor(z: R|test/Z|, @R|test/Ann|() s: R|kotlin/String|): R|test/Test|
|
||||
|
||||
public constructor(z: R|test/Z|): R|test/Test|
|
||||
@R|test/Ann|() public constructor(@R|test/Ann|() z: R|test/Z|): R|test/Test|
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final var property: R|kotlin/Int|
|
||||
@FIELD:R|test/Anno|() public final var property: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
|
||||
@@ -8,6 +8,6 @@ public final inline class Z : R|kotlin/Any| {
|
||||
public final val value: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
internal constructor(value: R|kotlin/Int|): R|test/Z|
|
||||
@R|kotlin/PublishedApi|() internal constructor(value: R|kotlin/Int|): R|test/Z|
|
||||
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ public final class A : R|kotlin/Any| {
|
||||
}
|
||||
|
||||
@R|test/A.Anno|() public final class B : R|kotlin/Any| {
|
||||
public final fun f(): R|kotlin/Unit|
|
||||
@R|test/A.Anno|() public final fun f(): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/B|
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
public final fun foo(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = R|java/lang/annotation/ElementType.METHOD|()) public final fun foo(): R|kotlin/Unit|
|
||||
|
||||
public final annotation class Anno : R|kotlin/Annotation| {
|
||||
public final val t: R|java/lang/annotation/ElementType|
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
public final fun baz(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = <implicitArrayOf>()) public final fun baz(): R|kotlin/Unit|
|
||||
|
||||
public final fun foo(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = <implicitArrayOf>(R|java/lang/annotation/ElementType.METHOD|(), R|java/lang/annotation/ElementType.FIELD|())) public final fun foo(): R|kotlin/Unit|
|
||||
|
||||
public final annotation class Anno : R|kotlin/Annotation| {
|
||||
public final val t: R|kotlin/Array<out java/lang/annotation/ElementType>|
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
public final fun function(): R|kotlin/Unit|
|
||||
@R|test/Anno|() public final fun function(): R|kotlin/Unit|
|
||||
|
||||
public final annotation class Anno : R|kotlin/Annotation| {
|
||||
public constructor(): R|test/Anno|
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
public final fun baz(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = <implicitArrayOf>()) public final fun baz(): R|kotlin/Unit|
|
||||
|
||||
public final fun foo(): R|kotlin/Unit|
|
||||
@R|test/Anno|(t = <implicitArrayOf>(String(live), String(long))) public final fun foo(): R|kotlin/Unit|
|
||||
|
||||
public final annotation class Anno : R|kotlin/Annotation| {
|
||||
public final val t: R|kotlin/Array<out kotlin/String>|
|
||||
|
||||
@@ -12,6 +12,6 @@ public final class Class : R|kotlin/Any| {
|
||||
public final val x: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public constructor(x: R|kotlin/Int|, y: R|kotlin/String|): R|test/Class|
|
||||
public constructor(@R|test/A|() x: R|kotlin/Int|, @R|test/B|() y: R|kotlin/String|): R|test/Class|
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
public final fun R|kotlin/Int|.foo(x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
public final fun R|kotlin/Int|.foo(@R|test/A|() x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
public final annotation class A : R|kotlin/Annotation| {
|
||||
public constructor(): R|test/A|
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final fun R|kotlin/String|.foo(x: R|kotlin/Int|): R|kotlin/Int|
|
||||
public final fun R|kotlin/String|.foo(@R|test/Anno|() x: R|kotlin/Int|): R|kotlin/Int|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ public final annotation class A : R|kotlin/Annotation| {
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final var R|kotlin/Int|.foo: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
public set(@R|test/A|() value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final fun foo(x: R|kotlin/String|): R|kotlin/Unit|
|
||||
public final fun foo(@R|test/Anno|() x: R|kotlin/String|): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
|
||||
@@ -4,6 +4,6 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public abstract interface Trait : R|kotlin/Any| {
|
||||
public open fun foo(x: R|kotlin/String|): R|kotlin/Int|
|
||||
public open fun foo(@R|test/Anno|() x: R|kotlin/String|): R|kotlin/Int|
|
||||
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
public final fun bar(x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
public final fun bar(@R|test/A|() @R|test/B|() @R|test/C|() @R|test/D|() x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
public final fun foo(x: R|kotlin/Int|, y: R|kotlin/Double|, z: R|kotlin/String|): R|kotlin/Unit|
|
||||
public final fun foo(@R|test/A|() @R|test/B|() x: R|kotlin/Int|, @R|test/A|() @R|test/C|() y: R|kotlin/Double|, @R|test/B|() @R|test/C|() @R|test/D|() z: R|kotlin/String|): R|kotlin/Unit|
|
||||
|
||||
public final annotation class A : R|kotlin/Annotation| {
|
||||
public constructor(): R|test/A|
|
||||
|
||||
@@ -6,7 +6,7 @@ public final annotation class A : R|kotlin/Annotation| {
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final var foo: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
public set(@R|test/A|() value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
public final fun foo(x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
public final fun foo(@R|test/Anno|() x: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
public final annotation class Anno : R|kotlin/Annotation| {
|
||||
public constructor(): R|test/Anno|
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final val property: R|kotlin/Int|
|
||||
@PROPERTY:R|test/Anno|() public final val property: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final val R|kotlin/Double|.extension: R|kotlin/Int|
|
||||
@PROPERTY:R|test/DoubleAnno|() public final val R|kotlin/Double|.extension: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public final val R|kotlin/Int|.extension: R|kotlin/Int|
|
||||
@PROPERTY:R|test/IntAnno|() public final val R|kotlin/Int|.extension: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public final val R|kotlin/String|.extension: R|kotlin/String|
|
||||
@PROPERTY:R|test/StringAnno|() public final val R|kotlin/String|.extension: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final val property: R|kotlin/String|
|
||||
@PROPERTY_DELEGATE_FIELD:R|test/Anno|() public final val property: R|kotlin/String|
|
||||
public get(): R|kotlin/String|
|
||||
|
||||
public constructor(): R|test/Class|
|
||||
|
||||
@@ -4,7 +4,7 @@ public final annotation class Anno : R|kotlin/Annotation| {
|
||||
}
|
||||
|
||||
public final class Class : R|kotlin/Any| {
|
||||
public final var property: R|kotlin/Int|
|
||||
@FIELD:R|test/Anno|() public final var property: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
public set(value: R|kotlin/Int|): R|kotlin/Unit|
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
public final class A : R|kotlin/Any| {
|
||||
public final fun R|kotlin/String|.myLength(q: R|kotlin/String|): R|kotlin/Int|
|
||||
public final fun R|kotlin/String|.myLength(@R|test/Ann|() q: R|kotlin/String|): R|kotlin/Int|
|
||||
|
||||
public final val R|kotlin/String|.myLength2: R|kotlin/Int|
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
@@ -4,7 +4,7 @@ public final class Test : R|kotlin/Any| {
|
||||
public final companion object Companion : R|kotlin/Any| {
|
||||
public final fun incProp4(): R|kotlin/Unit|
|
||||
|
||||
public final const val constProp8: R|kotlin/Int|
|
||||
public final const val constProp8: R|kotlin/Int| = Int(80)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public final val prop1: R|kotlin/Int|
|
||||
|
||||
@@ -2,7 +2,7 @@ public abstract interface Test : R|kotlin/Any| {
|
||||
public final companion object Companion : R|kotlin/Any| {
|
||||
public final fun incProp4(): R|kotlin/Unit|
|
||||
|
||||
public final const val constProp8: R|kotlin/Int|
|
||||
public final const val constProp8: R|kotlin/Int| = Int(80)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
public final val prop1: R|kotlin/Int|
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
public final object A : R|kotlin/Any| {
|
||||
internal final const val inObject: R|kotlin/Int|
|
||||
internal final const val inObject: R|kotlin/Int| = Int(2)
|
||||
internal get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|test/A|
|
||||
@@ -10,7 +10,7 @@ public final class B : R|kotlin/Any| {
|
||||
public constructor(): R|test/B|
|
||||
|
||||
public final companion object Companion : R|kotlin/Any| {
|
||||
public final const val inCompanion: R|kotlin/Int|
|
||||
public final const val inCompanion: R|kotlin/Int| = Int(3)
|
||||
public get(): R|kotlin/Int|
|
||||
|
||||
private constructor(): R|test/B.Companion|
|
||||
|
||||
@@ -5,94 +5,100 @@ digraph annotatedLocalClass_kt {
|
||||
|
||||
subgraph cluster_0 {
|
||||
color=red
|
||||
0 [label="Enter function <init>" style="filled" fillcolor=red];
|
||||
2 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
|
||||
1 [label="Exit function <init>" style="filled" fillcolor=red];
|
||||
0 [label="Enter class Ann" style="filled" fillcolor=red];
|
||||
1 [label="Exit class Ann" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {2};
|
||||
2 -> {1};
|
||||
0 -> {1} [color=green];
|
||||
|
||||
subgraph cluster_1 {
|
||||
color=red
|
||||
3 [label="Enter class Ann" style="filled" fillcolor=red];
|
||||
4 [label="Exit class Ann" style="filled" fillcolor=red];
|
||||
2 [label="Enter function <init>" style="filled" fillcolor=red];
|
||||
3 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
|
||||
4 [label="Exit function <init>" style="filled" fillcolor=red];
|
||||
}
|
||||
3 -> {4} [color=green];
|
||||
2 -> {3};
|
||||
3 -> {4};
|
||||
|
||||
subgraph cluster_2 {
|
||||
color=red
|
||||
5 [label="Enter function foo" style="filled" fillcolor=red];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
7 [label="Enter when"];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
9 [label="Enter when branch condition "];
|
||||
10 [label="Access variable R|<local>/b|"];
|
||||
11 [label="Exit when branch condition"];
|
||||
}
|
||||
18 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
23 [label="Enter class Local" style="filled" fillcolor=red];
|
||||
24 [label="Exit class Local" style="filled" fillcolor=red];
|
||||
}
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
6 [label="Enter block"];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Jump: ^foo Unit"];
|
||||
15 [label="Stub" style="filled" fillcolor=gray];
|
||||
16 [label="Exit block" style="filled" fillcolor=gray];
|
||||
7 [label="Enter when"];
|
||||
subgraph cluster_6 {
|
||||
color=blue
|
||||
8 [label="Enter when branch condition "];
|
||||
9 [label="Access variable R|<local>/b|"];
|
||||
10 [label="Exit when branch condition"];
|
||||
}
|
||||
11 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Jump: ^foo Unit"];
|
||||
15 [label="Stub" style="filled" fillcolor=gray];
|
||||
16 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
17 [label="Exit when branch result" style="filled" fillcolor=gray];
|
||||
18 [label="Exit when"];
|
||||
}
|
||||
17 [label="Exit when branch result" style="filled" fillcolor=gray];
|
||||
8 [label="Exit when"];
|
||||
19 [label="Exit local class foo"];
|
||||
20 [label="Function call: R|/bar|()"];
|
||||
21 [label="Exit block"];
|
||||
}
|
||||
subgraph cluster_6 {
|
||||
color=blue
|
||||
19 [label="Enter annotation"];
|
||||
20 [label="Exit annotation"];
|
||||
}
|
||||
21 [label="Exit local class foo"];
|
||||
22 [label="Function call: R|/bar|()"];
|
||||
6 [label="Exit function foo" style="filled" fillcolor=red];
|
||||
22 [label="Exit function foo" style="filled" fillcolor=red];
|
||||
}
|
||||
5 -> {7};
|
||||
7 -> {9};
|
||||
8 -> {19};
|
||||
5 -> {6};
|
||||
6 -> {7};
|
||||
7 -> {8};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {11};
|
||||
11 -> {12 18};
|
||||
10 -> {12 11};
|
||||
11 -> {18};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
14 -> {6};
|
||||
14 -> {22};
|
||||
14 -> {15} [style=dotted];
|
||||
15 -> {16} [style=dotted];
|
||||
16 -> {17} [style=dotted];
|
||||
17 -> {8} [style=dotted];
|
||||
18 -> {8};
|
||||
17 -> {18} [style=dotted];
|
||||
18 -> {19};
|
||||
18 -> {25} [color=red];
|
||||
19 -> {20};
|
||||
20 -> {21};
|
||||
20 -> {23} [color=red];
|
||||
21 -> {22};
|
||||
22 -> {6};
|
||||
|
||||
subgraph cluster_7 {
|
||||
color=red
|
||||
23 [label="Enter function <init>" style="filled" fillcolor=red];
|
||||
25 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
|
||||
24 [label="Exit function <init>" style="filled" fillcolor=red];
|
||||
}
|
||||
23 -> {25};
|
||||
25 -> {24};
|
||||
23 -> {24} [color=green];
|
||||
|
||||
subgraph cluster_8 {
|
||||
color=red
|
||||
26 [label="Enter class Local" style="filled" fillcolor=red];
|
||||
27 [label="Exit class Local" style="filled" fillcolor=red];
|
||||
25 [label="Enter function <init>" style="filled" fillcolor=red];
|
||||
26 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
|
||||
27 [label="Exit function <init>" style="filled" fillcolor=red];
|
||||
}
|
||||
26 -> {27} [color=green];
|
||||
25 -> {26};
|
||||
26 -> {27};
|
||||
|
||||
subgraph cluster_9 {
|
||||
color=red
|
||||
28 [label="Enter function bar" style="filled" fillcolor=red];
|
||||
29 [label="Exit function bar" style="filled" fillcolor=red];
|
||||
subgraph cluster_10 {
|
||||
color=blue
|
||||
29 [label="Enter block"];
|
||||
30 [label="Exit block"];
|
||||
}
|
||||
31 [label="Exit function bar" style="filled" fillcolor=red];
|
||||
}
|
||||
28 -> {29};
|
||||
29 -> {30};
|
||||
30 -> {31};
|
||||
|
||||
}
|
||||
|
||||
@@ -8,229 +8,257 @@ digraph binaryOperations_kt {
|
||||
0 [label="Enter function test_1" style="filled" fillcolor=red];
|
||||
subgraph cluster_1 {
|
||||
color=blue
|
||||
2 [label="Enter when"];
|
||||
1 [label="Enter block"];
|
||||
subgraph cluster_2 {
|
||||
color=blue
|
||||
4 [label="Enter when branch condition "];
|
||||
2 [label="Enter when"];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
6 [label="Enter ||"];
|
||||
7 [label="Access variable R|<local>/b1|"];
|
||||
8 [label="Exit left part of ||"];
|
||||
9 [label="Enter right part of ||"];
|
||||
10 [label="Access variable R|<local>/b2|"];
|
||||
5 [label="Exit ||"];
|
||||
3 [label="Enter when branch condition "];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
4 [label="Enter ||"];
|
||||
5 [label="Access variable R|<local>/b1|"];
|
||||
6 [label="Exit left part of ||"];
|
||||
7 [label="Enter right part of ||"];
|
||||
8 [label="Access variable R|<local>/b2|"];
|
||||
9 [label="Exit ||"];
|
||||
}
|
||||
10 [label="Exit when branch condition"];
|
||||
}
|
||||
11 [label="Exit when branch condition"];
|
||||
11 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Const: Int(1)"];
|
||||
15 [label="Exit block"];
|
||||
}
|
||||
16 [label="Exit when branch result"];
|
||||
17 [label="Exit when"];
|
||||
}
|
||||
17 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Const: Int(1)"];
|
||||
15 [label="Exit block"];
|
||||
}
|
||||
16 [label="Exit when branch result"];
|
||||
3 [label="Exit when"];
|
||||
18 [label="Exit block"];
|
||||
}
|
||||
1 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
19 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {2};
|
||||
2 -> {4};
|
||||
3 -> {1};
|
||||
4 -> {6};
|
||||
5 -> {11};
|
||||
6 -> {7};
|
||||
0 -> {1};
|
||||
1 -> {2};
|
||||
2 -> {3};
|
||||
3 -> {4};
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {9 7};
|
||||
7 -> {8};
|
||||
8 -> {5 9};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {5};
|
||||
11 -> {12 17};
|
||||
10 -> {12 11};
|
||||
11 -> {17};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
14 -> {15};
|
||||
15 -> {16};
|
||||
16 -> {3};
|
||||
17 -> {3};
|
||||
16 -> {17};
|
||||
17 -> {18};
|
||||
18 -> {19};
|
||||
|
||||
subgraph cluster_5 {
|
||||
subgraph cluster_6 {
|
||||
color=red
|
||||
18 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_6 {
|
||||
20 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
20 [label="Enter when"];
|
||||
subgraph cluster_7 {
|
||||
21 [label="Enter block"];
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
22 [label="Enter when branch condition "];
|
||||
subgraph cluster_8 {
|
||||
22 [label="Enter when"];
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
24 [label="Enter &&"];
|
||||
25 [label="Access variable R|<local>/b1|"];
|
||||
26 [label="Exit left part of &&"];
|
||||
27 [label="Enter right part of &&"];
|
||||
28 [label="Access variable R|<local>/b2|"];
|
||||
23 [label="Exit &&"];
|
||||
23 [label="Enter when branch condition "];
|
||||
subgraph cluster_10 {
|
||||
color=blue
|
||||
24 [label="Enter &&"];
|
||||
25 [label="Access variable R|<local>/b1|"];
|
||||
26 [label="Exit left part of &&"];
|
||||
27 [label="Enter right part of &&"];
|
||||
28 [label="Access variable R|<local>/b2|"];
|
||||
29 [label="Exit &&"];
|
||||
}
|
||||
30 [label="Exit when branch condition"];
|
||||
}
|
||||
29 [label="Exit when branch condition"];
|
||||
31 [label="Synthetic else branch"];
|
||||
32 [label="Enter when branch result"];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
33 [label="Enter block"];
|
||||
34 [label="Const: Int(1)"];
|
||||
35 [label="Exit block"];
|
||||
}
|
||||
36 [label="Exit when branch result"];
|
||||
37 [label="Exit when"];
|
||||
}
|
||||
35 [label="Synthetic else branch"];
|
||||
30 [label="Enter when branch result"];
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
31 [label="Enter block"];
|
||||
32 [label="Const: Int(1)"];
|
||||
33 [label="Exit block"];
|
||||
}
|
||||
34 [label="Exit when branch result"];
|
||||
21 [label="Exit when"];
|
||||
38 [label="Exit block"];
|
||||
}
|
||||
19 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
39 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
}
|
||||
18 -> {20};
|
||||
20 -> {22};
|
||||
21 -> {19};
|
||||
22 -> {24};
|
||||
23 -> {29};
|
||||
20 -> {21};
|
||||
21 -> {22};
|
||||
22 -> {23};
|
||||
23 -> {24};
|
||||
24 -> {25};
|
||||
25 -> {26};
|
||||
26 -> {23 27};
|
||||
26 -> {29 27};
|
||||
27 -> {28};
|
||||
28 -> {23};
|
||||
29 -> {30 35};
|
||||
30 -> {31};
|
||||
31 -> {32};
|
||||
28 -> {29};
|
||||
29 -> {30};
|
||||
30 -> {32 31};
|
||||
31 -> {37};
|
||||
32 -> {33};
|
||||
33 -> {34};
|
||||
34 -> {21};
|
||||
35 -> {21};
|
||||
34 -> {35};
|
||||
35 -> {36};
|
||||
36 -> {37};
|
||||
37 -> {38};
|
||||
38 -> {39};
|
||||
|
||||
subgraph cluster_10 {
|
||||
subgraph cluster_12 {
|
||||
color=red
|
||||
36 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_11 {
|
||||
40 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
38 [label="Enter when"];
|
||||
subgraph cluster_12 {
|
||||
41 [label="Enter block"];
|
||||
subgraph cluster_14 {
|
||||
color=blue
|
||||
40 [label="Enter when branch condition "];
|
||||
subgraph cluster_13 {
|
||||
42 [label="Enter when"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
42 [label="Enter ||"];
|
||||
subgraph cluster_14 {
|
||||
43 [label="Enter when branch condition "];
|
||||
subgraph cluster_16 {
|
||||
color=blue
|
||||
44 [label="Enter &&"];
|
||||
45 [label="Access variable R|<local>/b1|"];
|
||||
46 [label="Exit left part of &&"];
|
||||
47 [label="Enter right part of &&"];
|
||||
48 [label="Access variable R|<local>/b2|"];
|
||||
43 [label="Exit &&"];
|
||||
44 [label="Enter ||"];
|
||||
subgraph cluster_17 {
|
||||
color=blue
|
||||
45 [label="Enter &&"];
|
||||
46 [label="Access variable R|<local>/b1|"];
|
||||
47 [label="Exit left part of &&"];
|
||||
48 [label="Enter right part of &&"];
|
||||
49 [label="Access variable R|<local>/b2|"];
|
||||
50 [label="Exit &&"];
|
||||
}
|
||||
51 [label="Exit left part of ||"];
|
||||
52 [label="Enter right part of ||"];
|
||||
53 [label="Access variable R|<local>/b3|"];
|
||||
54 [label="Exit ||"];
|
||||
}
|
||||
49 [label="Exit left part of ||"];
|
||||
50 [label="Enter right part of ||"];
|
||||
51 [label="Access variable R|<local>/b3|"];
|
||||
41 [label="Exit ||"];
|
||||
55 [label="Exit when branch condition"];
|
||||
}
|
||||
52 [label="Exit when branch condition"];
|
||||
56 [label="Synthetic else branch"];
|
||||
57 [label="Enter when branch result"];
|
||||
subgraph cluster_18 {
|
||||
color=blue
|
||||
58 [label="Enter block"];
|
||||
59 [label="Const: Int(1)"];
|
||||
60 [label="Exit block"];
|
||||
}
|
||||
61 [label="Exit when branch result"];
|
||||
62 [label="Exit when"];
|
||||
}
|
||||
58 [label="Synthetic else branch"];
|
||||
53 [label="Enter when branch result"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
54 [label="Enter block"];
|
||||
55 [label="Const: Int(1)"];
|
||||
56 [label="Exit block"];
|
||||
}
|
||||
57 [label="Exit when branch result"];
|
||||
39 [label="Exit when"];
|
||||
63 [label="Exit block"];
|
||||
}
|
||||
37 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
64 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
}
|
||||
36 -> {38};
|
||||
38 -> {40};
|
||||
39 -> {37};
|
||||
40 -> {42};
|
||||
41 -> {52};
|
||||
42 -> {44};
|
||||
43 -> {49};
|
||||
40 -> {41};
|
||||
41 -> {42};
|
||||
42 -> {43};
|
||||
43 -> {44};
|
||||
44 -> {45};
|
||||
45 -> {46};
|
||||
46 -> {43 47};
|
||||
47 -> {48};
|
||||
48 -> {43};
|
||||
49 -> {41 50};
|
||||
46 -> {47};
|
||||
47 -> {50 48};
|
||||
48 -> {49};
|
||||
49 -> {50};
|
||||
50 -> {51};
|
||||
51 -> {41};
|
||||
52 -> {53 58};
|
||||
51 -> {54 52};
|
||||
52 -> {53};
|
||||
53 -> {54};
|
||||
54 -> {55};
|
||||
55 -> {56};
|
||||
56 -> {57};
|
||||
57 -> {39};
|
||||
58 -> {39};
|
||||
55 -> {57 56};
|
||||
56 -> {62};
|
||||
57 -> {58};
|
||||
58 -> {59};
|
||||
59 -> {60};
|
||||
60 -> {61};
|
||||
61 -> {62};
|
||||
62 -> {63};
|
||||
63 -> {64};
|
||||
|
||||
subgraph cluster_16 {
|
||||
subgraph cluster_19 {
|
||||
color=red
|
||||
59 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
subgraph cluster_17 {
|
||||
65 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
subgraph cluster_20 {
|
||||
color=blue
|
||||
61 [label="Enter when"];
|
||||
subgraph cluster_18 {
|
||||
color=blue
|
||||
63 [label="Enter when branch condition "];
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
65 [label="Enter ||"];
|
||||
66 [label="Access variable R|<local>/b1|"];
|
||||
67 [label="Exit left part of ||"];
|
||||
68 [label="Enter right part of ||"];
|
||||
subgraph cluster_20 {
|
||||
color=blue
|
||||
70 [label="Enter &&"];
|
||||
71 [label="Access variable R|<local>/b2|"];
|
||||
72 [label="Exit left part of &&"];
|
||||
73 [label="Enter right part of &&"];
|
||||
74 [label="Access variable R|<local>/b3|"];
|
||||
69 [label="Exit &&"];
|
||||
}
|
||||
64 [label="Exit ||"];
|
||||
}
|
||||
75 [label="Exit when branch condition"];
|
||||
}
|
||||
81 [label="Synthetic else branch"];
|
||||
76 [label="Enter when branch result"];
|
||||
66 [label="Enter block"];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
77 [label="Enter block"];
|
||||
78 [label="Const: Int(1)"];
|
||||
79 [label="Exit block"];
|
||||
67 [label="Enter when"];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
68 [label="Enter when branch condition "];
|
||||
subgraph cluster_23 {
|
||||
color=blue
|
||||
69 [label="Enter ||"];
|
||||
70 [label="Access variable R|<local>/b1|"];
|
||||
71 [label="Exit left part of ||"];
|
||||
72 [label="Enter right part of ||"];
|
||||
subgraph cluster_24 {
|
||||
color=blue
|
||||
73 [label="Enter &&"];
|
||||
74 [label="Access variable R|<local>/b2|"];
|
||||
75 [label="Exit left part of &&"];
|
||||
76 [label="Enter right part of &&"];
|
||||
77 [label="Access variable R|<local>/b3|"];
|
||||
78 [label="Exit &&"];
|
||||
}
|
||||
79 [label="Exit ||"];
|
||||
}
|
||||
80 [label="Exit when branch condition"];
|
||||
}
|
||||
81 [label="Synthetic else branch"];
|
||||
82 [label="Enter when branch result"];
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
83 [label="Enter block"];
|
||||
84 [label="Const: Int(1)"];
|
||||
85 [label="Exit block"];
|
||||
}
|
||||
86 [label="Exit when branch result"];
|
||||
87 [label="Exit when"];
|
||||
}
|
||||
80 [label="Exit when branch result"];
|
||||
62 [label="Exit when"];
|
||||
88 [label="Exit block"];
|
||||
}
|
||||
60 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
89 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
}
|
||||
59 -> {61};
|
||||
61 -> {63};
|
||||
62 -> {60};
|
||||
63 -> {65};
|
||||
64 -> {75};
|
||||
65 -> {66};
|
||||
66 -> {67};
|
||||
67 -> {64 68};
|
||||
68 -> {70};
|
||||
69 -> {64};
|
||||
67 -> {68};
|
||||
68 -> {69};
|
||||
69 -> {70};
|
||||
70 -> {71};
|
||||
71 -> {72};
|
||||
72 -> {69 73};
|
||||
71 -> {79 72};
|
||||
72 -> {73};
|
||||
73 -> {74};
|
||||
74 -> {69};
|
||||
75 -> {76 81};
|
||||
74 -> {75};
|
||||
75 -> {78 76};
|
||||
76 -> {77};
|
||||
77 -> {78};
|
||||
78 -> {79};
|
||||
79 -> {80};
|
||||
80 -> {62};
|
||||
81 -> {62};
|
||||
80 -> {82 81};
|
||||
81 -> {87};
|
||||
82 -> {83};
|
||||
83 -> {84};
|
||||
84 -> {85};
|
||||
85 -> {86};
|
||||
86 -> {87};
|
||||
87 -> {88};
|
||||
88 -> {89};
|
||||
|
||||
}
|
||||
|
||||
@@ -8,411 +8,467 @@ digraph booleanOperatorsWithConsts_kt {
|
||||
0 [label="Enter function test_1" style="filled" fillcolor=red];
|
||||
subgraph cluster_1 {
|
||||
color=blue
|
||||
2 [label="Enter when"];
|
||||
1 [label="Enter block"];
|
||||
subgraph cluster_2 {
|
||||
color=blue
|
||||
4 [label="Enter when branch condition "];
|
||||
2 [label="Enter when"];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
6 [label="Enter ||"];
|
||||
7 [label="Access variable R|<local>/b|"];
|
||||
8 [label="Exit left part of ||"];
|
||||
9 [label="Enter right part of ||"];
|
||||
10 [label="Const: Boolean(false)"];
|
||||
5 [label="Exit ||"];
|
||||
3 [label="Enter when branch condition "];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
4 [label="Enter ||"];
|
||||
5 [label="Access variable R|<local>/b|"];
|
||||
6 [label="Exit left part of ||"];
|
||||
7 [label="Enter right part of ||"];
|
||||
8 [label="Const: Boolean(false)"];
|
||||
9 [label="Exit ||"];
|
||||
}
|
||||
10 [label="Exit when branch condition"];
|
||||
}
|
||||
11 [label="Exit when branch condition"];
|
||||
11 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Const: Int(1)"];
|
||||
15 [label="Exit block"];
|
||||
}
|
||||
16 [label="Exit when branch result"];
|
||||
17 [label="Exit when"];
|
||||
}
|
||||
17 [label="Synthetic else branch"];
|
||||
12 [label="Enter when branch result"];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
13 [label="Enter block"];
|
||||
14 [label="Const: Int(1)"];
|
||||
15 [label="Exit block"];
|
||||
}
|
||||
16 [label="Exit when branch result"];
|
||||
3 [label="Exit when"];
|
||||
18 [label="Exit block"];
|
||||
}
|
||||
1 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
19 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {2};
|
||||
2 -> {4};
|
||||
3 -> {1};
|
||||
4 -> {6};
|
||||
5 -> {11};
|
||||
6 -> {7};
|
||||
0 -> {1};
|
||||
1 -> {2};
|
||||
2 -> {3};
|
||||
3 -> {4};
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {9 7};
|
||||
7 -> {8};
|
||||
8 -> {5 9};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {5};
|
||||
11 -> {12 17};
|
||||
10 -> {12 11};
|
||||
11 -> {17};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
14 -> {15};
|
||||
15 -> {16};
|
||||
16 -> {3};
|
||||
17 -> {3};
|
||||
16 -> {17};
|
||||
17 -> {18};
|
||||
18 -> {19};
|
||||
|
||||
subgraph cluster_5 {
|
||||
subgraph cluster_6 {
|
||||
color=red
|
||||
18 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_6 {
|
||||
20 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
20 [label="Enter when"];
|
||||
subgraph cluster_7 {
|
||||
21 [label="Enter block"];
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
22 [label="Enter when branch condition "];
|
||||
subgraph cluster_8 {
|
||||
22 [label="Enter when"];
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
24 [label="Enter ||"];
|
||||
25 [label="Const: Boolean(false)"];
|
||||
26 [label="Exit left part of ||"];
|
||||
27 [label="Enter right part of ||"];
|
||||
28 [label="Access variable R|<local>/b|"];
|
||||
23 [label="Exit ||"];
|
||||
23 [label="Enter when branch condition "];
|
||||
subgraph cluster_10 {
|
||||
color=blue
|
||||
24 [label="Enter ||"];
|
||||
25 [label="Const: Boolean(false)"];
|
||||
26 [label="Exit left part of ||"];
|
||||
27 [label="Enter right part of ||"];
|
||||
28 [label="Access variable R|<local>/b|"];
|
||||
29 [label="Exit ||"];
|
||||
}
|
||||
30 [label="Exit when branch condition"];
|
||||
}
|
||||
29 [label="Exit when branch condition"];
|
||||
31 [label="Synthetic else branch"];
|
||||
32 [label="Enter when branch result"];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
33 [label="Enter block"];
|
||||
34 [label="Const: Int(1)"];
|
||||
35 [label="Exit block"];
|
||||
}
|
||||
36 [label="Exit when branch result"];
|
||||
37 [label="Exit when"];
|
||||
}
|
||||
35 [label="Synthetic else branch"];
|
||||
30 [label="Enter when branch result"];
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
31 [label="Enter block"];
|
||||
32 [label="Const: Int(1)"];
|
||||
33 [label="Exit block"];
|
||||
}
|
||||
34 [label="Exit when branch result"];
|
||||
21 [label="Exit when"];
|
||||
38 [label="Exit block"];
|
||||
}
|
||||
19 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
39 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
}
|
||||
18 -> {20};
|
||||
20 -> {22};
|
||||
21 -> {19};
|
||||
22 -> {24};
|
||||
23 -> {29};
|
||||
20 -> {21};
|
||||
21 -> {22};
|
||||
22 -> {23};
|
||||
23 -> {24};
|
||||
24 -> {25};
|
||||
25 -> {26};
|
||||
26 -> {27};
|
||||
26 -> {23} [style=dotted];
|
||||
26 -> {29} [style=dotted];
|
||||
27 -> {28};
|
||||
28 -> {23};
|
||||
29 -> {30 35};
|
||||
30 -> {31};
|
||||
31 -> {32};
|
||||
28 -> {29};
|
||||
29 -> {30};
|
||||
30 -> {32 31};
|
||||
31 -> {37};
|
||||
32 -> {33};
|
||||
33 -> {34};
|
||||
34 -> {21};
|
||||
35 -> {21};
|
||||
34 -> {35};
|
||||
35 -> {36};
|
||||
36 -> {37};
|
||||
37 -> {38};
|
||||
38 -> {39};
|
||||
|
||||
subgraph cluster_10 {
|
||||
subgraph cluster_12 {
|
||||
color=red
|
||||
36 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_11 {
|
||||
40 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
38 [label="Enter when"];
|
||||
subgraph cluster_12 {
|
||||
color=blue
|
||||
40 [label="Enter when branch condition "];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
42 [label="Enter ||"];
|
||||
43 [label="Access variable R|<local>/b|"];
|
||||
44 [label="Exit left part of ||"];
|
||||
45 [label="Enter right part of ||"];
|
||||
46 [label="Const: Boolean(true)"];
|
||||
41 [label="Exit ||"];
|
||||
}
|
||||
47 [label="Exit when branch condition"];
|
||||
}
|
||||
53 [label="Synthetic else branch"];
|
||||
48 [label="Enter when branch result"];
|
||||
41 [label="Enter block"];
|
||||
subgraph cluster_14 {
|
||||
color=blue
|
||||
49 [label="Enter block"];
|
||||
50 [label="Const: Int(1)"];
|
||||
51 [label="Exit block"];
|
||||
42 [label="Enter when"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
43 [label="Enter when branch condition "];
|
||||
subgraph cluster_16 {
|
||||
color=blue
|
||||
44 [label="Enter ||"];
|
||||
45 [label="Access variable R|<local>/b|"];
|
||||
46 [label="Exit left part of ||"];
|
||||
47 [label="Enter right part of ||"];
|
||||
48 [label="Const: Boolean(true)"];
|
||||
49 [label="Exit ||"];
|
||||
}
|
||||
50 [label="Exit when branch condition"];
|
||||
}
|
||||
51 [label="Synthetic else branch"];
|
||||
52 [label="Enter when branch result"];
|
||||
subgraph cluster_17 {
|
||||
color=blue
|
||||
53 [label="Enter block"];
|
||||
54 [label="Const: Int(1)"];
|
||||
55 [label="Exit block"];
|
||||
}
|
||||
56 [label="Exit when branch result"];
|
||||
57 [label="Exit when"];
|
||||
}
|
||||
52 [label="Exit when branch result"];
|
||||
39 [label="Exit when"];
|
||||
58 [label="Exit block"];
|
||||
}
|
||||
37 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
59 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
}
|
||||
36 -> {38};
|
||||
38 -> {40};
|
||||
39 -> {37};
|
||||
40 -> {42};
|
||||
41 -> {47};
|
||||
40 -> {41};
|
||||
41 -> {42};
|
||||
42 -> {43};
|
||||
43 -> {44};
|
||||
44 -> {41 45};
|
||||
44 -> {45};
|
||||
45 -> {46};
|
||||
46 -> {41};
|
||||
47 -> {48 53};
|
||||
46 -> {49 47};
|
||||
47 -> {48};
|
||||
48 -> {49};
|
||||
49 -> {50};
|
||||
50 -> {51};
|
||||
51 -> {52};
|
||||
52 -> {39};
|
||||
53 -> {39};
|
||||
50 -> {52 51};
|
||||
51 -> {57};
|
||||
52 -> {53};
|
||||
53 -> {54};
|
||||
54 -> {55};
|
||||
55 -> {56};
|
||||
56 -> {57};
|
||||
57 -> {58};
|
||||
58 -> {59};
|
||||
|
||||
subgraph cluster_15 {
|
||||
subgraph cluster_18 {
|
||||
color=red
|
||||
54 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
subgraph cluster_16 {
|
||||
60 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
56 [label="Enter when"];
|
||||
subgraph cluster_17 {
|
||||
61 [label="Enter block"];
|
||||
subgraph cluster_20 {
|
||||
color=blue
|
||||
58 [label="Enter when branch condition "];
|
||||
subgraph cluster_18 {
|
||||
62 [label="Enter when"];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
60 [label="Enter ||"];
|
||||
61 [label="Const: Boolean(true)"];
|
||||
62 [label="Exit left part of ||"];
|
||||
63 [label="Enter right part of ||" style="filled" fillcolor=gray];
|
||||
64 [label="Access variable R|<local>/b|" style="filled" fillcolor=gray];
|
||||
59 [label="Exit ||"];
|
||||
63 [label="Enter when branch condition "];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
64 [label="Enter ||"];
|
||||
65 [label="Const: Boolean(true)"];
|
||||
66 [label="Exit left part of ||"];
|
||||
67 [label="Enter right part of ||" style="filled" fillcolor=gray];
|
||||
68 [label="Access variable R|<local>/b|" style="filled" fillcolor=gray];
|
||||
69 [label="Exit ||"];
|
||||
}
|
||||
70 [label="Exit when branch condition"];
|
||||
}
|
||||
65 [label="Exit when branch condition"];
|
||||
}
|
||||
71 [label="Synthetic else branch"];
|
||||
66 [label="Enter when branch result"];
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
67 [label="Enter block"];
|
||||
68 [label="Const: Int(1)"];
|
||||
69 [label="Exit block"];
|
||||
}
|
||||
70 [label="Exit when branch result"];
|
||||
57 [label="Exit when"];
|
||||
}
|
||||
55 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
}
|
||||
54 -> {56};
|
||||
56 -> {58};
|
||||
57 -> {55};
|
||||
58 -> {60};
|
||||
59 -> {65};
|
||||
60 -> {61};
|
||||
61 -> {62};
|
||||
62 -> {59};
|
||||
62 -> {63} [style=dotted];
|
||||
63 -> {64} [style=dotted];
|
||||
64 -> {59} [style=dotted];
|
||||
65 -> {66 71};
|
||||
66 -> {67};
|
||||
67 -> {68};
|
||||
68 -> {69};
|
||||
69 -> {70};
|
||||
70 -> {57};
|
||||
71 -> {57};
|
||||
|
||||
subgraph cluster_20 {
|
||||
color=red
|
||||
72 [label="Enter function test_5" style="filled" fillcolor=red];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
74 [label="Enter when"];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
76 [label="Enter when branch condition "];
|
||||
71 [label="Synthetic else branch"];
|
||||
72 [label="Enter when branch result"];
|
||||
subgraph cluster_23 {
|
||||
color=blue
|
||||
78 [label="Enter &&"];
|
||||
79 [label="Access variable R|<local>/b|"];
|
||||
80 [label="Exit left part of &&"];
|
||||
81 [label="Enter right part of &&"];
|
||||
82 [label="Const: Boolean(false)"];
|
||||
77 [label="Exit &&"];
|
||||
73 [label="Enter block"];
|
||||
74 [label="Const: Int(1)"];
|
||||
75 [label="Exit block"];
|
||||
}
|
||||
83 [label="Exit when branch condition"];
|
||||
76 [label="Exit when branch result"];
|
||||
77 [label="Exit when"];
|
||||
}
|
||||
89 [label="Synthetic else branch"];
|
||||
84 [label="Enter when branch result"];
|
||||
subgraph cluster_24 {
|
||||
color=blue
|
||||
85 [label="Enter block"];
|
||||
86 [label="Const: Int(1)"];
|
||||
87 [label="Exit block"];
|
||||
}
|
||||
88 [label="Exit when branch result"];
|
||||
75 [label="Exit when"];
|
||||
78 [label="Exit block"];
|
||||
}
|
||||
73 [label="Exit function test_5" style="filled" fillcolor=red];
|
||||
79 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
}
|
||||
72 -> {74};
|
||||
74 -> {76};
|
||||
75 -> {73};
|
||||
76 -> {78};
|
||||
77 -> {83};
|
||||
60 -> {61};
|
||||
61 -> {62};
|
||||
62 -> {63};
|
||||
63 -> {64};
|
||||
64 -> {65};
|
||||
65 -> {66};
|
||||
66 -> {69};
|
||||
66 -> {67} [style=dotted];
|
||||
67 -> {68} [style=dotted];
|
||||
68 -> {69} [style=dotted];
|
||||
69 -> {70};
|
||||
70 -> {72 71};
|
||||
71 -> {77};
|
||||
72 -> {73};
|
||||
73 -> {74};
|
||||
74 -> {75};
|
||||
75 -> {76};
|
||||
76 -> {77};
|
||||
77 -> {78};
|
||||
78 -> {79};
|
||||
79 -> {80};
|
||||
80 -> {77 81};
|
||||
|
||||
subgraph cluster_24 {
|
||||
color=red
|
||||
80 [label="Enter function test_5" style="filled" fillcolor=red];
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
81 [label="Enter block"];
|
||||
subgraph cluster_26 {
|
||||
color=blue
|
||||
82 [label="Enter when"];
|
||||
subgraph cluster_27 {
|
||||
color=blue
|
||||
83 [label="Enter when branch condition "];
|
||||
subgraph cluster_28 {
|
||||
color=blue
|
||||
84 [label="Enter &&"];
|
||||
85 [label="Access variable R|<local>/b|"];
|
||||
86 [label="Exit left part of &&"];
|
||||
87 [label="Enter right part of &&"];
|
||||
88 [label="Const: Boolean(false)"];
|
||||
89 [label="Exit &&"];
|
||||
}
|
||||
90 [label="Exit when branch condition"];
|
||||
}
|
||||
91 [label="Synthetic else branch"];
|
||||
92 [label="Enter when branch result"];
|
||||
subgraph cluster_29 {
|
||||
color=blue
|
||||
93 [label="Enter block"];
|
||||
94 [label="Const: Int(1)"];
|
||||
95 [label="Exit block"];
|
||||
}
|
||||
96 [label="Exit when branch result"];
|
||||
97 [label="Exit when"];
|
||||
}
|
||||
98 [label="Exit block"];
|
||||
}
|
||||
99 [label="Exit function test_5" style="filled" fillcolor=red];
|
||||
}
|
||||
80 -> {81};
|
||||
81 -> {82};
|
||||
82 -> {77};
|
||||
83 -> {84 89};
|
||||
82 -> {83};
|
||||
83 -> {84};
|
||||
84 -> {85};
|
||||
85 -> {86};
|
||||
86 -> {87};
|
||||
86 -> {89 87};
|
||||
87 -> {88};
|
||||
88 -> {75};
|
||||
89 -> {75};
|
||||
|
||||
subgraph cluster_25 {
|
||||
color=red
|
||||
90 [label="Enter function test_6" style="filled" fillcolor=red];
|
||||
subgraph cluster_26 {
|
||||
color=blue
|
||||
92 [label="Enter when"];
|
||||
subgraph cluster_27 {
|
||||
color=blue
|
||||
94 [label="Enter when branch condition "];
|
||||
subgraph cluster_28 {
|
||||
color=blue
|
||||
96 [label="Enter &&"];
|
||||
97 [label="Const: Boolean(false)"];
|
||||
98 [label="Exit left part of &&"];
|
||||
99 [label="Enter right part of &&" style="filled" fillcolor=gray];
|
||||
100 [label="Access variable R|<local>/b|" style="filled" fillcolor=gray];
|
||||
95 [label="Exit &&"];
|
||||
}
|
||||
101 [label="Exit when branch condition"];
|
||||
}
|
||||
107 [label="Synthetic else branch"];
|
||||
102 [label="Enter when branch result"];
|
||||
subgraph cluster_29 {
|
||||
color=blue
|
||||
103 [label="Enter block"];
|
||||
104 [label="Const: Int(1)"];
|
||||
105 [label="Exit block"];
|
||||
}
|
||||
106 [label="Exit when branch result"];
|
||||
93 [label="Exit when"];
|
||||
}
|
||||
91 [label="Exit function test_6" style="filled" fillcolor=red];
|
||||
}
|
||||
90 -> {92};
|
||||
92 -> {94};
|
||||
93 -> {91};
|
||||
94 -> {96};
|
||||
95 -> {101};
|
||||
88 -> {89};
|
||||
89 -> {90};
|
||||
90 -> {92 91};
|
||||
91 -> {97};
|
||||
92 -> {93};
|
||||
93 -> {94};
|
||||
94 -> {95};
|
||||
95 -> {96};
|
||||
96 -> {97};
|
||||
97 -> {98};
|
||||
98 -> {95};
|
||||
98 -> {99} [style=dotted];
|
||||
99 -> {100} [style=dotted];
|
||||
100 -> {95} [style=dotted];
|
||||
101 -> {102 107};
|
||||
98 -> {99};
|
||||
|
||||
subgraph cluster_30 {
|
||||
color=red
|
||||
100 [label="Enter function test_6" style="filled" fillcolor=red];
|
||||
subgraph cluster_31 {
|
||||
color=blue
|
||||
101 [label="Enter block"];
|
||||
subgraph cluster_32 {
|
||||
color=blue
|
||||
102 [label="Enter when"];
|
||||
subgraph cluster_33 {
|
||||
color=blue
|
||||
103 [label="Enter when branch condition "];
|
||||
subgraph cluster_34 {
|
||||
color=blue
|
||||
104 [label="Enter &&"];
|
||||
105 [label="Const: Boolean(false)"];
|
||||
106 [label="Exit left part of &&"];
|
||||
107 [label="Enter right part of &&" style="filled" fillcolor=gray];
|
||||
108 [label="Access variable R|<local>/b|" style="filled" fillcolor=gray];
|
||||
109 [label="Exit &&"];
|
||||
}
|
||||
110 [label="Exit when branch condition"];
|
||||
}
|
||||
111 [label="Synthetic else branch"];
|
||||
112 [label="Enter when branch result"];
|
||||
subgraph cluster_35 {
|
||||
color=blue
|
||||
113 [label="Enter block"];
|
||||
114 [label="Const: Int(1)"];
|
||||
115 [label="Exit block"];
|
||||
}
|
||||
116 [label="Exit when branch result"];
|
||||
117 [label="Exit when"];
|
||||
}
|
||||
118 [label="Exit block"];
|
||||
}
|
||||
119 [label="Exit function test_6" style="filled" fillcolor=red];
|
||||
}
|
||||
100 -> {101};
|
||||
101 -> {102};
|
||||
102 -> {103};
|
||||
103 -> {104};
|
||||
104 -> {105};
|
||||
105 -> {106};
|
||||
106 -> {93};
|
||||
107 -> {93};
|
||||
|
||||
subgraph cluster_30 {
|
||||
color=red
|
||||
108 [label="Enter function test_7" style="filled" fillcolor=red];
|
||||
subgraph cluster_31 {
|
||||
color=blue
|
||||
110 [label="Enter when"];
|
||||
subgraph cluster_32 {
|
||||
color=blue
|
||||
112 [label="Enter when branch condition "];
|
||||
subgraph cluster_33 {
|
||||
color=blue
|
||||
114 [label="Enter &&"];
|
||||
115 [label="Access variable R|<local>/b|"];
|
||||
116 [label="Exit left part of &&"];
|
||||
117 [label="Enter right part of &&"];
|
||||
118 [label="Const: Boolean(true)"];
|
||||
113 [label="Exit &&"];
|
||||
}
|
||||
119 [label="Exit when branch condition"];
|
||||
}
|
||||
125 [label="Synthetic else branch"];
|
||||
120 [label="Enter when branch result"];
|
||||
subgraph cluster_34 {
|
||||
color=blue
|
||||
121 [label="Enter block"];
|
||||
122 [label="Const: Int(1)"];
|
||||
123 [label="Exit block"];
|
||||
}
|
||||
124 [label="Exit when branch result"];
|
||||
111 [label="Exit when"];
|
||||
}
|
||||
109 [label="Exit function test_7" style="filled" fillcolor=red];
|
||||
}
|
||||
108 -> {110};
|
||||
110 -> {112};
|
||||
111 -> {109};
|
||||
112 -> {114};
|
||||
113 -> {119};
|
||||
106 -> {109};
|
||||
106 -> {107} [style=dotted];
|
||||
107 -> {108} [style=dotted];
|
||||
108 -> {109} [style=dotted];
|
||||
109 -> {110};
|
||||
110 -> {112 111};
|
||||
111 -> {117};
|
||||
112 -> {113};
|
||||
113 -> {114};
|
||||
114 -> {115};
|
||||
115 -> {116};
|
||||
116 -> {113 117};
|
||||
116 -> {117};
|
||||
117 -> {118};
|
||||
118 -> {113};
|
||||
119 -> {120 125};
|
||||
118 -> {119};
|
||||
|
||||
subgraph cluster_36 {
|
||||
color=red
|
||||
120 [label="Enter function test_7" style="filled" fillcolor=red];
|
||||
subgraph cluster_37 {
|
||||
color=blue
|
||||
121 [label="Enter block"];
|
||||
subgraph cluster_38 {
|
||||
color=blue
|
||||
122 [label="Enter when"];
|
||||
subgraph cluster_39 {
|
||||
color=blue
|
||||
123 [label="Enter when branch condition "];
|
||||
subgraph cluster_40 {
|
||||
color=blue
|
||||
124 [label="Enter &&"];
|
||||
125 [label="Access variable R|<local>/b|"];
|
||||
126 [label="Exit left part of &&"];
|
||||
127 [label="Enter right part of &&"];
|
||||
128 [label="Const: Boolean(true)"];
|
||||
129 [label="Exit &&"];
|
||||
}
|
||||
130 [label="Exit when branch condition"];
|
||||
}
|
||||
131 [label="Synthetic else branch"];
|
||||
132 [label="Enter when branch result"];
|
||||
subgraph cluster_41 {
|
||||
color=blue
|
||||
133 [label="Enter block"];
|
||||
134 [label="Const: Int(1)"];
|
||||
135 [label="Exit block"];
|
||||
}
|
||||
136 [label="Exit when branch result"];
|
||||
137 [label="Exit when"];
|
||||
}
|
||||
138 [label="Exit block"];
|
||||
}
|
||||
139 [label="Exit function test_7" style="filled" fillcolor=red];
|
||||
}
|
||||
120 -> {121};
|
||||
121 -> {122};
|
||||
122 -> {123};
|
||||
123 -> {124};
|
||||
124 -> {111};
|
||||
125 -> {111};
|
||||
|
||||
subgraph cluster_35 {
|
||||
color=red
|
||||
126 [label="Enter function test_8" style="filled" fillcolor=red];
|
||||
subgraph cluster_36 {
|
||||
color=blue
|
||||
128 [label="Enter when"];
|
||||
subgraph cluster_37 {
|
||||
color=blue
|
||||
130 [label="Enter when branch condition "];
|
||||
subgraph cluster_38 {
|
||||
color=blue
|
||||
132 [label="Enter &&"];
|
||||
133 [label="Const: Boolean(true)"];
|
||||
134 [label="Exit left part of &&"];
|
||||
135 [label="Enter right part of &&"];
|
||||
136 [label="Access variable R|<local>/b|"];
|
||||
131 [label="Exit &&"];
|
||||
}
|
||||
137 [label="Exit when branch condition"];
|
||||
}
|
||||
143 [label="Synthetic else branch"];
|
||||
138 [label="Enter when branch result"];
|
||||
subgraph cluster_39 {
|
||||
color=blue
|
||||
139 [label="Enter block"];
|
||||
140 [label="Const: Int(1)"];
|
||||
141 [label="Exit block"];
|
||||
}
|
||||
142 [label="Exit when branch result"];
|
||||
129 [label="Exit when"];
|
||||
}
|
||||
127 [label="Exit function test_8" style="filled" fillcolor=red];
|
||||
}
|
||||
126 -> {128};
|
||||
128 -> {130};
|
||||
129 -> {127};
|
||||
130 -> {132};
|
||||
124 -> {125};
|
||||
125 -> {126};
|
||||
126 -> {129 127};
|
||||
127 -> {128};
|
||||
128 -> {129};
|
||||
129 -> {130};
|
||||
130 -> {132 131};
|
||||
131 -> {137};
|
||||
132 -> {133};
|
||||
133 -> {134};
|
||||
134 -> {135};
|
||||
134 -> {131} [style=dotted];
|
||||
135 -> {136};
|
||||
136 -> {131};
|
||||
137 -> {138 143};
|
||||
136 -> {137};
|
||||
137 -> {138};
|
||||
138 -> {139};
|
||||
139 -> {140};
|
||||
|
||||
subgraph cluster_42 {
|
||||
color=red
|
||||
140 [label="Enter function test_8" style="filled" fillcolor=red];
|
||||
subgraph cluster_43 {
|
||||
color=blue
|
||||
141 [label="Enter block"];
|
||||
subgraph cluster_44 {
|
||||
color=blue
|
||||
142 [label="Enter when"];
|
||||
subgraph cluster_45 {
|
||||
color=blue
|
||||
143 [label="Enter when branch condition "];
|
||||
subgraph cluster_46 {
|
||||
color=blue
|
||||
144 [label="Enter &&"];
|
||||
145 [label="Const: Boolean(true)"];
|
||||
146 [label="Exit left part of &&"];
|
||||
147 [label="Enter right part of &&"];
|
||||
148 [label="Access variable R|<local>/b|"];
|
||||
149 [label="Exit &&"];
|
||||
}
|
||||
150 [label="Exit when branch condition"];
|
||||
}
|
||||
151 [label="Synthetic else branch"];
|
||||
152 [label="Enter when branch result"];
|
||||
subgraph cluster_47 {
|
||||
color=blue
|
||||
153 [label="Enter block"];
|
||||
154 [label="Const: Int(1)"];
|
||||
155 [label="Exit block"];
|
||||
}
|
||||
156 [label="Exit when branch result"];
|
||||
157 [label="Exit when"];
|
||||
}
|
||||
158 [label="Exit block"];
|
||||
}
|
||||
159 [label="Exit function test_8" style="filled" fillcolor=red];
|
||||
}
|
||||
140 -> {141};
|
||||
141 -> {142};
|
||||
142 -> {129};
|
||||
143 -> {129};
|
||||
142 -> {143};
|
||||
143 -> {144};
|
||||
144 -> {145};
|
||||
145 -> {146};
|
||||
146 -> {147};
|
||||
146 -> {149} [style=dotted];
|
||||
147 -> {148};
|
||||
148 -> {149};
|
||||
149 -> {150};
|
||||
150 -> {152 151};
|
||||
151 -> {157};
|
||||
152 -> {153};
|
||||
153 -> {154};
|
||||
154 -> {155};
|
||||
155 -> {156};
|
||||
156 -> {157};
|
||||
157 -> {158};
|
||||
158 -> {159};
|
||||
|
||||
}
|
||||
|
||||
@@ -5,106 +5,116 @@ digraph complex_kt {
|
||||
|
||||
subgraph cluster_0 {
|
||||
color=red
|
||||
0 [label="Enter function close" style="filled" fillcolor=red];
|
||||
1 [label="Exit function close" style="filled" fillcolor=red];
|
||||
0 [label="Enter class AutoCloseable" style="filled" fillcolor=red];
|
||||
1 [label="Exit class AutoCloseable" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {1};
|
||||
0 -> {1} [color=green];
|
||||
|
||||
subgraph cluster_1 {
|
||||
color=red
|
||||
2 [label="Enter class AutoCloseable" style="filled" fillcolor=red];
|
||||
3 [label="Exit class AutoCloseable" style="filled" fillcolor=red];
|
||||
2 [label="Enter function close" style="filled" fillcolor=red];
|
||||
3 [label="Exit function close" style="filled" fillcolor=red];
|
||||
}
|
||||
2 -> {3} [color=green];
|
||||
2 -> {3};
|
||||
|
||||
subgraph cluster_2 {
|
||||
color=red
|
||||
4 [label="Enter function addSuppressed" style="filled" fillcolor=red];
|
||||
5 [label="Exit function addSuppressed" style="filled" fillcolor=red];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
5 [label="Enter block"];
|
||||
6 [label="Exit block"];
|
||||
}
|
||||
7 [label="Exit function addSuppressed" style="filled" fillcolor=red];
|
||||
}
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {7};
|
||||
|
||||
subgraph cluster_3 {
|
||||
subgraph cluster_4 {
|
||||
color=red
|
||||
6 [label="Enter function closeFinally" style="filled" fillcolor=red];
|
||||
subgraph cluster_4 {
|
||||
8 [label="Enter function closeFinally" style="filled" fillcolor=red];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
8 [label="Enter when"];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
10 [label="Enter when branch condition "];
|
||||
11 [label="Access variable this@R|/closeFinally|"];
|
||||
12 [label="Const: Null(null)"];
|
||||
13 [label="Operator =="];
|
||||
14 [label="Exit when branch condition"];
|
||||
}
|
||||
9 [label="Enter block"];
|
||||
subgraph cluster_6 {
|
||||
color=blue
|
||||
19 [label="Enter when branch condition "];
|
||||
20 [label="Access variable R|<local>/cause|"];
|
||||
21 [label="Const: Null(null)"];
|
||||
22 [label="Operator =="];
|
||||
23 [label="Exit when branch condition"];
|
||||
}
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
29 [label="Enter when branch condition else"];
|
||||
30 [label="Exit when branch condition"];
|
||||
}
|
||||
31 [label="Enter when branch result"];
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
32 [label="Enter block"];
|
||||
10 [label="Enter when"];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
11 [label="Enter when branch condition "];
|
||||
12 [label="Access variable this@R|/closeFinally|"];
|
||||
13 [label="Const: Null(null)"];
|
||||
14 [label="Operator =="];
|
||||
15 [label="Exit when branch condition"];
|
||||
}
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
16 [label="Enter when branch condition "];
|
||||
17 [label="Access variable R|<local>/cause|"];
|
||||
18 [label="Const: Null(null)"];
|
||||
19 [label="Operator =="];
|
||||
20 [label="Exit when branch condition"];
|
||||
}
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
33 [label="Try expression enter"];
|
||||
subgraph cluster_10 {
|
||||
color=blue
|
||||
35 [label="Try main block enter"];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
37 [label="Enter block"];
|
||||
38 [label="Function call: this@R|/closeFinally|.R|/AutoCloseable.close|()"];
|
||||
39 [label="Exit block"];
|
||||
}
|
||||
40 [label="Try main block exit"];
|
||||
}
|
||||
subgraph cluster_12 {
|
||||
color=blue
|
||||
36 [label="Catch enter"];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
41 [label="Enter block"];
|
||||
42 [label="Access variable R|<local>/cause|"];
|
||||
43 [label="Access variable R|<local>/closeException|"];
|
||||
44 [label="Function call: R|<local>/cause|.R|/addSuppressed|(...)"];
|
||||
45 [label="Exit block"];
|
||||
}
|
||||
46 [label="Catch exit"];
|
||||
}
|
||||
34 [label="Try expression exit"];
|
||||
21 [label="Enter when branch condition else"];
|
||||
22 [label="Exit when branch condition"];
|
||||
}
|
||||
47 [label="Exit block"];
|
||||
23 [label="Enter when branch result"];
|
||||
subgraph cluster_10 {
|
||||
color=blue
|
||||
24 [label="Enter block"];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
25 [label="Try expression enter"];
|
||||
subgraph cluster_12 {
|
||||
color=blue
|
||||
26 [label="Try main block enter"];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
27 [label="Enter block"];
|
||||
28 [label="Function call: this@R|/closeFinally|.R|/AutoCloseable.close|()"];
|
||||
29 [label="Exit block"];
|
||||
}
|
||||
30 [label="Try main block exit"];
|
||||
}
|
||||
subgraph cluster_14 {
|
||||
color=blue
|
||||
31 [label="Catch enter"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
32 [label="Enter block"];
|
||||
33 [label="Access variable R|<local>/cause|"];
|
||||
34 [label="Access variable R|<local>/closeException|"];
|
||||
35 [label="Function call: R|<local>/cause|.R|/addSuppressed|(...)"];
|
||||
36 [label="Exit block"];
|
||||
}
|
||||
37 [label="Catch exit"];
|
||||
}
|
||||
38 [label="Try expression exit"];
|
||||
}
|
||||
39 [label="Exit block"];
|
||||
}
|
||||
40 [label="Exit when branch result"];
|
||||
41 [label="Enter when branch result"];
|
||||
subgraph cluster_16 {
|
||||
color=blue
|
||||
42 [label="Enter block"];
|
||||
43 [label="Function call: this@R|/closeFinally|.R|/AutoCloseable.close|()"];
|
||||
44 [label="Exit block"];
|
||||
}
|
||||
45 [label="Exit when branch result"];
|
||||
46 [label="Enter when branch result"];
|
||||
subgraph cluster_17 {
|
||||
color=blue
|
||||
47 [label="Enter block"];
|
||||
48 [label="Exit block"];
|
||||
}
|
||||
49 [label="Exit when branch result"];
|
||||
50 [label="Exit when"];
|
||||
}
|
||||
48 [label="Exit when branch result"];
|
||||
24 [label="Enter when branch result"];
|
||||
subgraph cluster_14 {
|
||||
color=blue
|
||||
25 [label="Enter block"];
|
||||
26 [label="Function call: this@R|/closeFinally|.R|/AutoCloseable.close|()"];
|
||||
27 [label="Exit block"];
|
||||
}
|
||||
28 [label="Exit when branch result"];
|
||||
15 [label="Enter when branch result"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
16 [label="Enter block"];
|
||||
17 [label="Exit block"];
|
||||
}
|
||||
18 [label="Exit when branch result"];
|
||||
9 [label="Exit when"];
|
||||
}
|
||||
49 [label="Jump: ^closeFinally when () {
|
||||
51 [label="Jump: ^closeFinally when () {
|
||||
==(this@R|/closeFinally|, Null(null)) -> {
|
||||
}
|
||||
==(R|<local>/cause|, Null(null)) -> {
|
||||
@@ -121,149 +131,160 @@ digraph complex_kt {
|
||||
}
|
||||
}
|
||||
"];
|
||||
50 [label="Stub" style="filled" fillcolor=gray];
|
||||
7 [label="Exit function closeFinally" style="filled" fillcolor=red];
|
||||
52 [label="Stub" style="filled" fillcolor=gray];
|
||||
53 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
54 [label="Exit function closeFinally" style="filled" fillcolor=red];
|
||||
}
|
||||
6 -> {8};
|
||||
8 -> {10};
|
||||
9 -> {49};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {11};
|
||||
11 -> {12};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
14 -> {15 19};
|
||||
15 -> {16};
|
||||
14 -> {15};
|
||||
15 -> {46 16};
|
||||
16 -> {17};
|
||||
17 -> {18};
|
||||
18 -> {9};
|
||||
18 -> {19};
|
||||
19 -> {20};
|
||||
20 -> {21};
|
||||
20 -> {41 21};
|
||||
21 -> {22};
|
||||
22 -> {23};
|
||||
23 -> {24 29};
|
||||
23 -> {24};
|
||||
24 -> {25};
|
||||
25 -> {26};
|
||||
26 -> {27};
|
||||
26 -> {54 31 27};
|
||||
27 -> {28};
|
||||
28 -> {9};
|
||||
28 -> {29};
|
||||
29 -> {30};
|
||||
30 -> {31};
|
||||
31 -> {32};
|
||||
30 -> {38};
|
||||
31 -> {54 32};
|
||||
32 -> {33};
|
||||
33 -> {35};
|
||||
34 -> {47};
|
||||
35 -> {7 36 37};
|
||||
36 -> {7 41};
|
||||
33 -> {34};
|
||||
34 -> {35};
|
||||
35 -> {36};
|
||||
36 -> {37};
|
||||
37 -> {38};
|
||||
38 -> {39};
|
||||
39 -> {40};
|
||||
40 -> {34};
|
||||
40 -> {50};
|
||||
41 -> {42};
|
||||
42 -> {43};
|
||||
43 -> {44};
|
||||
44 -> {45};
|
||||
45 -> {46};
|
||||
46 -> {34};
|
||||
45 -> {50};
|
||||
46 -> {47};
|
||||
47 -> {48};
|
||||
48 -> {9};
|
||||
49 -> {7};
|
||||
49 -> {50} [style=dotted];
|
||||
50 -> {7} [style=dotted];
|
||||
48 -> {49};
|
||||
49 -> {50};
|
||||
50 -> {51};
|
||||
51 -> {54};
|
||||
51 -> {52} [style=dotted];
|
||||
52 -> {53} [style=dotted];
|
||||
53 -> {54} [style=dotted];
|
||||
|
||||
subgraph cluster_16 {
|
||||
subgraph cluster_18 {
|
||||
color=red
|
||||
51 [label="Enter function firstIsInstanceOrNull" style="filled" fillcolor=red];
|
||||
53 [label="Access variable this@R|/firstIsInstanceOrNull|"];
|
||||
54 [label="Function call: this@R|/firstIsInstanceOrNull|.R|FakeOverride<kotlin/collections/List.iterator: R|kotlin/collections/Iterator<kotlin/Any?>|>|()"];
|
||||
55 [label="Variable declaration: lval <iterator>: R|kotlin/collections/Iterator<kotlin/Any?>|"];
|
||||
subgraph cluster_17 {
|
||||
55 [label="Enter function firstIsInstanceOrNull" style="filled" fillcolor=red];
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
56 [label="Enter while loop"];
|
||||
subgraph cluster_18 {
|
||||
56 [label="Enter block"];
|
||||
57 [label="Access variable this@R|/firstIsInstanceOrNull|"];
|
||||
58 [label="Function call: this@R|/firstIsInstanceOrNull|.R|FakeOverride<kotlin/collections/List.iterator: R|kotlin/collections/Iterator<kotlin/Any?>|>|()"];
|
||||
59 [label="Variable declaration: lval <iterator>: R|kotlin/collections/Iterator<kotlin/Any?>|"];
|
||||
subgraph cluster_20 {
|
||||
color=blue
|
||||
58 [label="Enter loop condition"];
|
||||
59 [label="Access variable R|<local>/<iterator>|"];
|
||||
60 [label="Function call: R|<local>/<iterator>|.R|kotlin/collections/Iterator.hasNext|()"];
|
||||
61 [label="Exit loop condition"];
|
||||
}
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
62 [label="Enter loop block"];
|
||||
subgraph cluster_20 {
|
||||
60 [label="Enter while loop"];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
63 [label="Enter block"];
|
||||
64 [label="Access variable R|<local>/<iterator>|"];
|
||||
65 [label="Function call: R|<local>/<iterator>|.R|FakeOverride<kotlin/collections/Iterator.next: R|kotlin/Any?|>|()"];
|
||||
66 [label="Variable declaration: lval element: R|kotlin/Any?|"];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
67 [label="Enter when"];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
69 [label="Enter when branch condition "];
|
||||
70 [label="Access variable R|<local>/element|"];
|
||||
71 [label="Type operator: (R|<local>/element| is R|T|)"];
|
||||
72 [label="Exit when branch condition"];
|
||||
}
|
||||
80 [label="Synthetic else branch"];
|
||||
73 [label="Enter when branch result"];
|
||||
subgraph cluster_23 {
|
||||
color=blue
|
||||
74 [label="Enter block"];
|
||||
75 [label="Access variable R|<local>/element|"];
|
||||
76 [label="Jump: ^firstIsInstanceOrNull R|<local>/element|"];
|
||||
77 [label="Stub" style="filled" fillcolor=gray];
|
||||
78 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
79 [label="Exit when branch result" style="filled" fillcolor=gray];
|
||||
68 [label="Exit when"];
|
||||
}
|
||||
81 [label="Exit block"];
|
||||
61 [label="Enter loop condition"];
|
||||
62 [label="Access variable R|<local>/<iterator>|"];
|
||||
63 [label="Function call: R|<local>/<iterator>|.R|kotlin/collections/Iterator.hasNext|()"];
|
||||
64 [label="Exit loop condition"];
|
||||
}
|
||||
82 [label="Exit loop block"];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
65 [label="Enter loop block"];
|
||||
subgraph cluster_23 {
|
||||
color=blue
|
||||
66 [label="Enter block"];
|
||||
67 [label="Access variable R|<local>/<iterator>|"];
|
||||
68 [label="Function call: R|<local>/<iterator>|.R|FakeOverride<kotlin/collections/Iterator.next: R|kotlin/Any?|>|()"];
|
||||
69 [label="Variable declaration: lval element: R|kotlin/Any?|"];
|
||||
subgraph cluster_24 {
|
||||
color=blue
|
||||
70 [label="Enter when"];
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
71 [label="Enter when branch condition "];
|
||||
72 [label="Access variable R|<local>/element|"];
|
||||
73 [label="Type operator: (R|<local>/element| is R|T|)"];
|
||||
74 [label="Exit when branch condition"];
|
||||
}
|
||||
75 [label="Synthetic else branch"];
|
||||
76 [label="Enter when branch result"];
|
||||
subgraph cluster_26 {
|
||||
color=blue
|
||||
77 [label="Enter block"];
|
||||
78 [label="Access variable R|<local>/element|"];
|
||||
79 [label="Jump: ^firstIsInstanceOrNull R|<local>/element|"];
|
||||
80 [label="Stub" style="filled" fillcolor=gray];
|
||||
81 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
82 [label="Exit when branch result" style="filled" fillcolor=gray];
|
||||
83 [label="Exit when"];
|
||||
}
|
||||
84 [label="Exit block"];
|
||||
}
|
||||
85 [label="Exit loop block"];
|
||||
}
|
||||
86 [label="Exit whileloop"];
|
||||
}
|
||||
57 [label="Exit whileloop"];
|
||||
87 [label="Const: Null(null)"];
|
||||
88 [label="Jump: ^firstIsInstanceOrNull Null(null)"];
|
||||
89 [label="Stub" style="filled" fillcolor=gray];
|
||||
90 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
83 [label="Const: Null(null)"];
|
||||
84 [label="Jump: ^firstIsInstanceOrNull Null(null)"];
|
||||
85 [label="Stub" style="filled" fillcolor=gray];
|
||||
52 [label="Exit function firstIsInstanceOrNull" style="filled" fillcolor=red];
|
||||
91 [label="Exit function firstIsInstanceOrNull" style="filled" fillcolor=red];
|
||||
}
|
||||
51 -> {53};
|
||||
53 -> {54};
|
||||
54 -> {55};
|
||||
55 -> {56};
|
||||
56 -> {58};
|
||||
57 -> {83};
|
||||
56 -> {57};
|
||||
57 -> {58};
|
||||
58 -> {59};
|
||||
59 -> {60};
|
||||
60 -> {61};
|
||||
61 -> {57 62};
|
||||
61 -> {62};
|
||||
62 -> {63};
|
||||
63 -> {64};
|
||||
64 -> {65};
|
||||
64 -> {86 65};
|
||||
65 -> {66};
|
||||
66 -> {67};
|
||||
67 -> {69};
|
||||
68 -> {81};
|
||||
67 -> {68};
|
||||
68 -> {69};
|
||||
69 -> {70};
|
||||
70 -> {71};
|
||||
71 -> {72};
|
||||
72 -> {73 80};
|
||||
72 -> {73};
|
||||
73 -> {74};
|
||||
74 -> {75};
|
||||
75 -> {76};
|
||||
76 -> {52};
|
||||
76 -> {77} [style=dotted];
|
||||
77 -> {78} [style=dotted];
|
||||
78 -> {79} [style=dotted];
|
||||
79 -> {68} [style=dotted];
|
||||
80 -> {68};
|
||||
81 -> {82};
|
||||
82 -> {58};
|
||||
74 -> {76 75};
|
||||
75 -> {83};
|
||||
76 -> {77};
|
||||
77 -> {78};
|
||||
78 -> {79};
|
||||
79 -> {91};
|
||||
79 -> {80} [style=dotted];
|
||||
80 -> {81} [style=dotted];
|
||||
81 -> {82} [style=dotted];
|
||||
82 -> {83} [style=dotted];
|
||||
83 -> {84};
|
||||
84 -> {52};
|
||||
84 -> {85} [style=dotted];
|
||||
85 -> {52} [style=dotted];
|
||||
84 -> {85};
|
||||
85 -> {61} [color=green style=dashed];
|
||||
86 -> {87};
|
||||
87 -> {88};
|
||||
88 -> {91};
|
||||
88 -> {89} [style=dotted];
|
||||
89 -> {90} [style=dotted];
|
||||
90 -> {91} [style=dotted];
|
||||
|
||||
}
|
||||
|
||||
85
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot
vendored
Normal file
85
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot
vendored
Normal file
@@ -0,0 +1,85 @@
|
||||
digraph defaultArguments_kt {
|
||||
graph [nodesep=3]
|
||||
node [shape=box penwidth=2]
|
||||
edge [penwidth=2]
|
||||
|
||||
subgraph cluster_0 {
|
||||
color=red
|
||||
0 [label="Enter function foo" style="filled" fillcolor=red];
|
||||
subgraph cluster_1 {
|
||||
color=blue
|
||||
1 [label="Enter block"];
|
||||
2 [label="Const: Int(1)"];
|
||||
3 [label="Jump: ^foo Int(1)"];
|
||||
4 [label="Stub" style="filled" fillcolor=gray];
|
||||
5 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
6 [label="Exit function foo" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {1};
|
||||
1 -> {2};
|
||||
2 -> {3};
|
||||
3 -> {6};
|
||||
3 -> {4} [style=dotted];
|
||||
4 -> {5} [style=dotted];
|
||||
5 -> {6} [style=dotted];
|
||||
|
||||
subgraph cluster_2 {
|
||||
color=red
|
||||
7 [label="Enter function test" style="filled" fillcolor=red];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
16 [label="Enter default value of z" style="filled" fillcolor=red];
|
||||
17 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
22 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
23 [label="Enter block"];
|
||||
24 [label="Function call: R|/foo|()"];
|
||||
25 [label="Exit block"];
|
||||
}
|
||||
26 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
18 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
19 [label="Postponed exit from lambda"];
|
||||
20 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
21 [label="Exit default value of z" style="filled" fillcolor=red];
|
||||
}
|
||||
subgraph cluster_6 {
|
||||
color=blue
|
||||
12 [label="Enter default value of y" style="filled" fillcolor=red];
|
||||
13 [label="Access variable R|<local>/x|"];
|
||||
14 [label="Type operator: (R|<local>/x| as R|kotlin/String|)"];
|
||||
15 [label="Exit default value of y" style="filled" fillcolor=red];
|
||||
}
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
8 [label="Enter block"];
|
||||
9 [label="Function call: R|/foo|()"];
|
||||
10 [label="Exit block"];
|
||||
}
|
||||
11 [label="Exit function test" style="filled" fillcolor=red];
|
||||
}
|
||||
7 -> {12 16 8};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {11};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
14 -> {15};
|
||||
16 -> {17};
|
||||
17 -> {22};
|
||||
17 -> {19} [color=red];
|
||||
18 -> {20} [color=red];
|
||||
19 -> {20} [color=green];
|
||||
20 -> {21};
|
||||
22 -> {23};
|
||||
23 -> {24};
|
||||
24 -> {25};
|
||||
25 -> {26};
|
||||
26 -> {18} [color=red];
|
||||
26 -> {19} [color=green];
|
||||
|
||||
}
|
||||
7
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.kt
vendored
Normal file
7
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.kt
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
// !DUMP_CFG
|
||||
|
||||
fun foo(): Int = 1
|
||||
|
||||
fun test(x: Any, y: String = x as String, z: Int = run { foo() }) {
|
||||
foo()
|
||||
}
|
||||
10
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.txt
vendored
Normal file
10
compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.txt
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
FILE: defaultArguments.kt
|
||||
public final fun foo(): R|kotlin/Int| {
|
||||
^foo Int(1)
|
||||
}
|
||||
public final fun test(x: R|kotlin/Any|, y: R|kotlin/String| = (R|<local>/x| as R|kotlin/String|), z: R|kotlin/Int| = R|kotlin/run|<R|kotlin/Int|>(<L> = run@fun <anonymous>(): R|kotlin/Int| <kind=EXACTLY_ONCE> {
|
||||
^ R|/foo|()
|
||||
}
|
||||
)): R|kotlin/Unit| {
|
||||
R|/foo|()
|
||||
}
|
||||
@@ -8,53 +8,74 @@ digraph emptyWhen_kt {
|
||||
0 [label="Enter function test_1" style="filled" fillcolor=red];
|
||||
subgraph cluster_1 {
|
||||
color=blue
|
||||
2 [label="Enter when"];
|
||||
4 [label="Synthetic else branch"];
|
||||
3 [label="Exit when"];
|
||||
1 [label="Enter block"];
|
||||
subgraph cluster_2 {
|
||||
color=blue
|
||||
2 [label="Enter when"];
|
||||
3 [label="Synthetic else branch"];
|
||||
4 [label="Exit when"];
|
||||
}
|
||||
5 [label="Exit block"];
|
||||
}
|
||||
1 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
6 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {2};
|
||||
2 -> {4};
|
||||
3 -> {1};
|
||||
4 -> {3};
|
||||
0 -> {1};
|
||||
1 -> {2};
|
||||
2 -> {3};
|
||||
3 -> {4};
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
|
||||
subgraph cluster_2 {
|
||||
subgraph cluster_3 {
|
||||
color=red
|
||||
5 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_3 {
|
||||
7 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
7 [label="Enter when"];
|
||||
9 [label="Access variable R|<local>/x|"];
|
||||
10 [label="Synthetic else branch"];
|
||||
8 [label="Exit when"];
|
||||
8 [label="Enter block"];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
9 [label="Enter when"];
|
||||
10 [label="Access variable R|<local>/x|"];
|
||||
11 [label="Synthetic else branch"];
|
||||
12 [label="Exit when"];
|
||||
}
|
||||
13 [label="Exit block"];
|
||||
}
|
||||
6 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
14 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
}
|
||||
5 -> {7};
|
||||
7 -> {9};
|
||||
8 -> {6};
|
||||
7 -> {8};
|
||||
8 -> {9};
|
||||
9 -> {10};
|
||||
10 -> {8};
|
||||
10 -> {11};
|
||||
11 -> {12};
|
||||
12 -> {13};
|
||||
13 -> {14};
|
||||
|
||||
subgraph cluster_4 {
|
||||
subgraph cluster_6 {
|
||||
color=red
|
||||
11 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_5 {
|
||||
15 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
13 [label="Enter when"];
|
||||
15 [label="Access variable R|<local>/x|"];
|
||||
16 [label="Variable declaration: lval y: R|kotlin/Int|"];
|
||||
17 [label="Synthetic else branch"];
|
||||
14 [label="Exit when"];
|
||||
16 [label="Enter block"];
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
17 [label="Enter when"];
|
||||
18 [label="Access variable R|<local>/x|"];
|
||||
19 [label="Variable declaration: lval y: R|kotlin/Int|"];
|
||||
20 [label="Synthetic else branch"];
|
||||
21 [label="Exit when"];
|
||||
}
|
||||
22 [label="Exit block"];
|
||||
}
|
||||
12 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
23 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
}
|
||||
11 -> {13};
|
||||
13 -> {15};
|
||||
14 -> {12};
|
||||
15 -> {16};
|
||||
16 -> {17};
|
||||
17 -> {14};
|
||||
17 -> {18};
|
||||
18 -> {19};
|
||||
19 -> {20};
|
||||
20 -> {21};
|
||||
21 -> {22};
|
||||
22 -> {23};
|
||||
|
||||
}
|
||||
|
||||
@@ -6,428 +6,579 @@ digraph flowFromInplaceLambda_kt {
|
||||
subgraph cluster_0 {
|
||||
color=red
|
||||
0 [label="Enter function takeInt" style="filled" fillcolor=red];
|
||||
1 [label="Exit function takeInt" style="filled" fillcolor=red];
|
||||
subgraph cluster_1 {
|
||||
color=blue
|
||||
1 [label="Enter block"];
|
||||
2 [label="Exit block"];
|
||||
}
|
||||
3 [label="Exit function takeInt" style="filled" fillcolor=red];
|
||||
}
|
||||
0 -> {1};
|
||||
|
||||
subgraph cluster_1 {
|
||||
color=red
|
||||
2 [label="Enter function select" style="filled" fillcolor=red];
|
||||
4 [label="Access variable R|<local>/x|"];
|
||||
5 [label="Const: Int(0)"];
|
||||
6 [label="Function call: R|<local>/x|.R|FakeOverride<kotlin/Array.get: R|K|>|(...)"];
|
||||
7 [label="Jump: ^select R|<local>/x|.R|FakeOverride<kotlin/Array.get: R|K|>|(Int(0))"];
|
||||
8 [label="Stub" style="filled" fillcolor=gray];
|
||||
3 [label="Exit function select" style="filled" fillcolor=red];
|
||||
}
|
||||
2 -> {4};
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {7};
|
||||
7 -> {3};
|
||||
7 -> {8} [style=dotted];
|
||||
8 -> {3} [style=dotted];
|
||||
1 -> {2};
|
||||
2 -> {3};
|
||||
|
||||
subgraph cluster_2 {
|
||||
color=red
|
||||
9 [label="Enter function id" style="filled" fillcolor=red];
|
||||
11 [label="Access variable R|<local>/x|"];
|
||||
12 [label="Jump: ^id R|<local>/x|"];
|
||||
13 [label="Stub" style="filled" fillcolor=gray];
|
||||
10 [label="Exit function id" style="filled" fillcolor=red];
|
||||
4 [label="Enter function select" style="filled" fillcolor=red];
|
||||
subgraph cluster_3 {
|
||||
color=blue
|
||||
5 [label="Enter block"];
|
||||
6 [label="Access variable R|<local>/x|"];
|
||||
7 [label="Const: Int(0)"];
|
||||
8 [label="Function call: R|<local>/x|.R|FakeOverride<kotlin/Array.get: R|K|>|(...)"];
|
||||
9 [label="Jump: ^select R|<local>/x|.R|FakeOverride<kotlin/Array.get: R|K|>|(Int(0))"];
|
||||
10 [label="Stub" style="filled" fillcolor=gray];
|
||||
11 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
12 [label="Exit function select" style="filled" fillcolor=red];
|
||||
}
|
||||
9 -> {11};
|
||||
11 -> {12};
|
||||
12 -> {10};
|
||||
12 -> {13} [style=dotted];
|
||||
13 -> {10} [style=dotted];
|
||||
|
||||
subgraph cluster_3 {
|
||||
color=red
|
||||
14 [label="Enter function materialize" style="filled" fillcolor=red];
|
||||
16 [label="Const: Null(null)"];
|
||||
17 [label="Check not null: Null(null)!!"];
|
||||
18 [label="Jump: ^materialize Null(null)!!"];
|
||||
19 [label="Stub" style="filled" fillcolor=gray];
|
||||
15 [label="Exit function materialize" style="filled" fillcolor=red];
|
||||
}
|
||||
14 -> {16};
|
||||
16 -> {17};
|
||||
17 -> {18};
|
||||
18 -> {15};
|
||||
18 -> {19} [style=dotted];
|
||||
19 -> {15} [style=dotted];
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {7};
|
||||
7 -> {8};
|
||||
8 -> {9};
|
||||
9 -> {12};
|
||||
9 -> {10} [style=dotted];
|
||||
10 -> {11} [style=dotted];
|
||||
11 -> {12} [style=dotted];
|
||||
|
||||
subgraph cluster_4 {
|
||||
color=red
|
||||
20 [label="Enter function myRun" style="filled" fillcolor=red];
|
||||
22 [label="Function call: R|<local>/block|.R|FakeOverride<kotlin/Function0.invoke: R|R|>|()"];
|
||||
23 [label="Jump: ^myRun R|<local>/block|.R|FakeOverride<kotlin/Function0.invoke: R|R|>|()"];
|
||||
24 [label="Stub" style="filled" fillcolor=gray];
|
||||
21 [label="Exit function myRun" style="filled" fillcolor=red];
|
||||
13 [label="Enter function id" style="filled" fillcolor=red];
|
||||
subgraph cluster_5 {
|
||||
color=blue
|
||||
14 [label="Enter block"];
|
||||
15 [label="Access variable R|<local>/x|"];
|
||||
16 [label="Jump: ^id R|<local>/x|"];
|
||||
17 [label="Stub" style="filled" fillcolor=gray];
|
||||
18 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
19 [label="Exit function id" style="filled" fillcolor=red];
|
||||
}
|
||||
20 -> {22};
|
||||
13 -> {14};
|
||||
14 -> {15};
|
||||
15 -> {16};
|
||||
16 -> {19};
|
||||
16 -> {17} [style=dotted];
|
||||
17 -> {18} [style=dotted];
|
||||
18 -> {19} [style=dotted];
|
||||
|
||||
subgraph cluster_6 {
|
||||
color=red
|
||||
20 [label="Enter function materialize" style="filled" fillcolor=red];
|
||||
subgraph cluster_7 {
|
||||
color=blue
|
||||
21 [label="Enter block"];
|
||||
22 [label="Const: Null(null)"];
|
||||
23 [label="Check not null: Null(null)!!"];
|
||||
24 [label="Jump: ^materialize Null(null)!!"];
|
||||
25 [label="Stub" style="filled" fillcolor=gray];
|
||||
26 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
27 [label="Exit function materialize" style="filled" fillcolor=red];
|
||||
}
|
||||
20 -> {21};
|
||||
21 -> {22};
|
||||
22 -> {23};
|
||||
23 -> {21};
|
||||
23 -> {24} [style=dotted];
|
||||
24 -> {21} [style=dotted];
|
||||
23 -> {24};
|
||||
24 -> {27};
|
||||
24 -> {25} [style=dotted];
|
||||
25 -> {26} [style=dotted];
|
||||
26 -> {27} [style=dotted];
|
||||
|
||||
subgraph cluster_5 {
|
||||
subgraph cluster_8 {
|
||||
color=red
|
||||
25 [label="Enter function test_1" style="filled" fillcolor=red];
|
||||
27 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_6 {
|
||||
color=blue
|
||||
33 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
35 [label="Access variable R|<local>/x|"];
|
||||
36 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
34 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
30 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
28 [label="Postponed exit from lambda"];
|
||||
29 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
31 [label="Access variable R|<local>/x|"];
|
||||
32 [label="Function call: R|/takeInt|(...)"];
|
||||
26 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
}
|
||||
25 -> {27};
|
||||
27 -> {33};
|
||||
27 -> {28} [color=red];
|
||||
28 -> {29} [color=green];
|
||||
29 -> {31};
|
||||
30 -> {29} [color=red];
|
||||
31 -> {32};
|
||||
32 -> {26};
|
||||
33 -> {35};
|
||||
34 -> {28} [color=green];
|
||||
34 -> {30} [color=red];
|
||||
35 -> {36};
|
||||
36 -> {34};
|
||||
|
||||
subgraph cluster_7 {
|
||||
color=red
|
||||
37 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
39 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_8 {
|
||||
color=blue
|
||||
58 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
60 [label="Access variable R|<local>/y|"];
|
||||
61 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
62 [label="Access variable R|<local>/x|"];
|
||||
63 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
59 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
40 [label="Postponed exit from lambda"];
|
||||
41 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
43 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
42 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
44 [label="Access variable R|<local>/y|"];
|
||||
45 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
46 [label="Postponed enter to lambda"];
|
||||
28 [label="Enter function myRun" style="filled" fillcolor=red];
|
||||
subgraph cluster_9 {
|
||||
color=blue
|
||||
64 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
66 [label="Access variable R|<local>/x|"];
|
||||
67 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()"];
|
||||
68 [label="Access variable R|<local>/y|"];
|
||||
69 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
70 [label="Const: Int(1)"];
|
||||
65 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
29 [label="Enter block"];
|
||||
30 [label="Function call: R|<local>/block|.R|FakeOverride<kotlin/Function0.invoke: R|R|>|()"];
|
||||
31 [label="Jump: ^myRun R|<local>/block|.R|FakeOverride<kotlin/Function0.invoke: R|R|>|()"];
|
||||
32 [label="Stub" style="filled" fillcolor=gray];
|
||||
33 [label="Exit block" style="filled" fillcolor=gray];
|
||||
}
|
||||
47 [label="Postponed exit from lambda"];
|
||||
48 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
50 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
49 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
51 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
52 [label="Access variable R|<local>/x|"];
|
||||
53 [label="Function call: R|/takeInt|(...)"];
|
||||
54 [label="Access variable R|<local>/y|"];
|
||||
55 [label="Function call: R|/takeInt|(...)"];
|
||||
56 [label="Access variable R|<local>/a|"];
|
||||
57 [label="Function call: R|/takeInt|(...)"];
|
||||
38 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
34 [label="Exit function myRun" style="filled" fillcolor=red];
|
||||
}
|
||||
37 -> {39};
|
||||
39 -> {58};
|
||||
39 -> {40} [color=red];
|
||||
28 -> {29};
|
||||
29 -> {30};
|
||||
30 -> {31};
|
||||
31 -> {34};
|
||||
31 -> {32} [style=dotted];
|
||||
32 -> {33} [style=dotted];
|
||||
33 -> {34} [style=dotted];
|
||||
|
||||
subgraph cluster_10 {
|
||||
color=red
|
||||
35 [label="Enter function test_1" style="filled" fillcolor=red];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
36 [label="Enter block"];
|
||||
37 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_12 {
|
||||
color=blue
|
||||
45 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_13 {
|
||||
color=blue
|
||||
46 [label="Enter block"];
|
||||
47 [label="Access variable R|<local>/x|"];
|
||||
48 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
49 [label="Exit block"];
|
||||
}
|
||||
50 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
38 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
39 [label="Postponed exit from lambda"];
|
||||
40 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
41 [label="Access variable R|<local>/x|"];
|
||||
42 [label="Function call: R|/takeInt|(...)"];
|
||||
43 [label="Exit block"];
|
||||
}
|
||||
44 [label="Exit function test_1" style="filled" fillcolor=red];
|
||||
}
|
||||
35 -> {36};
|
||||
36 -> {37};
|
||||
37 -> {45};
|
||||
37 -> {39} [color=red];
|
||||
38 -> {40} [color=red];
|
||||
39 -> {40} [color=green];
|
||||
40 -> {41};
|
||||
41 -> {43};
|
||||
42 -> {44};
|
||||
43 -> {42};
|
||||
44 -> {45};
|
||||
41 -> {42};
|
||||
42 -> {43};
|
||||
43 -> {44};
|
||||
45 -> {46};
|
||||
46 -> {64};
|
||||
46 -> {47} [color=red];
|
||||
46 -> {47};
|
||||
47 -> {48};
|
||||
48 -> {50};
|
||||
49 -> {51};
|
||||
50 -> {49};
|
||||
48 -> {49};
|
||||
49 -> {50};
|
||||
50 -> {38} [color=red];
|
||||
50 -> {39} [color=green];
|
||||
|
||||
subgraph cluster_14 {
|
||||
color=red
|
||||
51 [label="Enter function test_2" style="filled" fillcolor=red];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
52 [label="Enter block"];
|
||||
53 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_16 {
|
||||
color=blue
|
||||
74 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_17 {
|
||||
color=blue
|
||||
75 [label="Enter block"];
|
||||
76 [label="Access variable R|<local>/y|"];
|
||||
77 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
78 [label="Access variable R|<local>/x|"];
|
||||
79 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
80 [label="Exit block"];
|
||||
}
|
||||
81 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
54 [label="Postponed exit from lambda"];
|
||||
55 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
56 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
57 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
58 [label="Access variable R|<local>/y|"];
|
||||
59 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
60 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_18 {
|
||||
color=blue
|
||||
82 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_19 {
|
||||
color=blue
|
||||
83 [label="Enter block"];
|
||||
84 [label="Access variable R|<local>/x|"];
|
||||
85 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()"];
|
||||
86 [label="Access variable R|<local>/y|"];
|
||||
87 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
88 [label="Const: Int(1)"];
|
||||
89 [label="Exit block"];
|
||||
}
|
||||
90 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
61 [label="Postponed exit from lambda"];
|
||||
62 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
63 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
64 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
65 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
66 [label="Access variable R|<local>/x|"];
|
||||
67 [label="Function call: R|/takeInt|(...)"];
|
||||
68 [label="Access variable R|<local>/y|"];
|
||||
69 [label="Function call: R|/takeInt|(...)"];
|
||||
70 [label="Access variable R|<local>/a|"];
|
||||
71 [label="Function call: R|/takeInt|(...)"];
|
||||
72 [label="Exit block"];
|
||||
}
|
||||
73 [label="Exit function test_2" style="filled" fillcolor=red];
|
||||
}
|
||||
51 -> {52};
|
||||
52 -> {53};
|
||||
53 -> {54};
|
||||
53 -> {74};
|
||||
53 -> {54} [color=red];
|
||||
54 -> {55};
|
||||
55 -> {56};
|
||||
56 -> {57};
|
||||
57 -> {38};
|
||||
58 -> {60};
|
||||
59 -> {40} [color=green];
|
||||
59 -> {43} [color=red];
|
||||
60 -> {61};
|
||||
57 -> {58};
|
||||
58 -> {59};
|
||||
59 -> {60};
|
||||
60 -> {82};
|
||||
60 -> {61} [color=red];
|
||||
61 -> {62};
|
||||
62 -> {63};
|
||||
63 -> {59};
|
||||
64 -> {66};
|
||||
65 -> {47} [color=green];
|
||||
65 -> {50} [color=red];
|
||||
63 -> {64};
|
||||
64 -> {65};
|
||||
65 -> {66};
|
||||
66 -> {67};
|
||||
67 -> {68};
|
||||
68 -> {69};
|
||||
69 -> {70};
|
||||
70 -> {65};
|
||||
|
||||
subgraph cluster_10 {
|
||||
color=red
|
||||
71 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
73 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_11 {
|
||||
color=blue
|
||||
89 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
91 [label="Access variable R|<local>/y|"];
|
||||
92 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
93 [label="Access variable R|<local>/x|"];
|
||||
94 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
95 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
90 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
74 [label="Postponed exit from lambda"];
|
||||
75 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
76 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
77 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_12 {
|
||||
color=blue
|
||||
96 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
98 [label="Access variable R|<local>/y|"];
|
||||
99 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
100 [label="Access variable R|<local>/x|"];
|
||||
101 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
|
||||
102 [label="Access variable R|<local>/y|"];
|
||||
103 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
104 [label="Const: Int(1)"];
|
||||
97 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
78 [label="Postponed exit from lambda"];
|
||||
79 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
81 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
80 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
82 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
83 [label="Access variable R|<local>/x|"];
|
||||
84 [label="Function call: R|/takeInt|(...)"];
|
||||
85 [label="Access variable R|<local>/y|"];
|
||||
86 [label="Function call: R|/takeInt|(...)"];
|
||||
87 [label="Access variable R|<local>/a|"];
|
||||
88 [label="Function call: R|/takeInt|(...)"];
|
||||
72 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
}
|
||||
71 -> {73};
|
||||
73 -> {89};
|
||||
73 -> {74} [color=red];
|
||||
70 -> {71};
|
||||
71 -> {72};
|
||||
72 -> {73};
|
||||
74 -> {75};
|
||||
75 -> {76};
|
||||
76 -> {77};
|
||||
77 -> {96};
|
||||
77 -> {78} [color=red];
|
||||
77 -> {78};
|
||||
78 -> {79};
|
||||
79 -> {81};
|
||||
80 -> {82};
|
||||
81 -> {80};
|
||||
79 -> {80};
|
||||
80 -> {81};
|
||||
81 -> {56} [color=red];
|
||||
81 -> {54} [color=green];
|
||||
82 -> {83};
|
||||
83 -> {84};
|
||||
84 -> {85};
|
||||
85 -> {86};
|
||||
86 -> {87};
|
||||
87 -> {88};
|
||||
88 -> {72};
|
||||
89 -> {91};
|
||||
90 -> {74} [color=green];
|
||||
90 -> {81} [color=red];
|
||||
88 -> {89};
|
||||
89 -> {90};
|
||||
90 -> {63} [color=red];
|
||||
90 -> {61} [color=green];
|
||||
|
||||
subgraph cluster_20 {
|
||||
color=red
|
||||
91 [label="Enter function test_3" style="filled" fillcolor=red];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
92 [label="Enter block"];
|
||||
93 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_22 {
|
||||
color=blue
|
||||
111 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_23 {
|
||||
color=blue
|
||||
112 [label="Enter block"];
|
||||
113 [label="Access variable R|<local>/y|"];
|
||||
114 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
115 [label="Access variable R|<local>/x|"];
|
||||
116 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
117 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
118 [label="Exit block"];
|
||||
}
|
||||
119 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
94 [label="Postponed exit from lambda"];
|
||||
95 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
96 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
97 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_24 {
|
||||
color=blue
|
||||
120 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
121 [label="Enter block"];
|
||||
122 [label="Access variable R|<local>/y|"];
|
||||
123 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
124 [label="Access variable R|<local>/x|"];
|
||||
125 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
|
||||
126 [label="Access variable R|<local>/y|"];
|
||||
127 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
128 [label="Const: Int(1)"];
|
||||
129 [label="Exit block"];
|
||||
}
|
||||
130 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
98 [label="Postponed exit from lambda"];
|
||||
99 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
100 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
101 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
102 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
103 [label="Access variable R|<local>/x|"];
|
||||
104 [label="Function call: R|/takeInt|(...)"];
|
||||
105 [label="Access variable R|<local>/y|"];
|
||||
106 [label="Function call: R|/takeInt|(...)"];
|
||||
107 [label="Access variable R|<local>/a|"];
|
||||
108 [label="Function call: R|/takeInt|(...)"];
|
||||
109 [label="Exit block"];
|
||||
}
|
||||
110 [label="Exit function test_3" style="filled" fillcolor=red];
|
||||
}
|
||||
91 -> {92};
|
||||
92 -> {93};
|
||||
93 -> {94};
|
||||
93 -> {111};
|
||||
93 -> {94} [color=red];
|
||||
94 -> {95};
|
||||
95 -> {90};
|
||||
96 -> {98};
|
||||
97 -> {78} [color=green];
|
||||
97 -> {81} [color=red];
|
||||
95 -> {96};
|
||||
96 -> {97};
|
||||
97 -> {120};
|
||||
97 -> {98} [color=red];
|
||||
98 -> {99};
|
||||
99 -> {100};
|
||||
100 -> {101};
|
||||
101 -> {102};
|
||||
102 -> {103};
|
||||
103 -> {104};
|
||||
104 -> {97};
|
||||
|
||||
subgraph cluster_13 {
|
||||
color=red
|
||||
105 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
107 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_14 {
|
||||
color=blue
|
||||
124 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
126 [label="Access variable R|<local>/y|"];
|
||||
127 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
128 [label="Access variable R|<local>/x|"];
|
||||
129 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
125 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
108 [label="Postponed exit from lambda"];
|
||||
109 [label="Function call: R|/myRun|<R|kotlin/Int|>(...)"];
|
||||
110 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
111 [label="Access variable R|<local>/y|"];
|
||||
112 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
113 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_15 {
|
||||
color=blue
|
||||
130 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
132 [label="Access variable R|<local>/x|"];
|
||||
133 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
|
||||
134 [label="Access variable R|<local>/y|"];
|
||||
135 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
136 [label="Const: Int(1)"];
|
||||
131 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
114 [label="Postponed exit from lambda"];
|
||||
115 [label="Function call: R|/myRun|<R|kotlin/Int|>(...)"];
|
||||
116 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
117 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
118 [label="Access variable R|<local>/x|"];
|
||||
119 [label="Function call: <Inapplicable(INAPPLICABLE): [/takeInt]>#(...)"];
|
||||
120 [label="Access variable R|<local>/y|"];
|
||||
121 [label="Function call: R|/takeInt|(...)"];
|
||||
122 [label="Access variable R|<local>/a|"];
|
||||
123 [label="Function call: R|/takeInt|(...)"];
|
||||
106 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
}
|
||||
105 -> {107};
|
||||
104 -> {105};
|
||||
105 -> {106};
|
||||
106 -> {107};
|
||||
107 -> {108};
|
||||
107 -> {124} [color=red];
|
||||
108 -> {109};
|
||||
109 -> {110};
|
||||
110 -> {111};
|
||||
111 -> {112};
|
||||
112 -> {113};
|
||||
113 -> {114};
|
||||
113 -> {130} [color=red];
|
||||
114 -> {115};
|
||||
115 -> {116};
|
||||
116 -> {117};
|
||||
117 -> {118};
|
||||
118 -> {119};
|
||||
119 -> {120};
|
||||
119 -> {100} [color=red];
|
||||
119 -> {94} [color=green];
|
||||
120 -> {121};
|
||||
121 -> {122};
|
||||
122 -> {123};
|
||||
123 -> {106};
|
||||
124 -> {126};
|
||||
123 -> {124};
|
||||
124 -> {125};
|
||||
125 -> {126};
|
||||
126 -> {127};
|
||||
127 -> {128};
|
||||
128 -> {129};
|
||||
129 -> {125};
|
||||
130 -> {132};
|
||||
129 -> {130};
|
||||
130 -> {100} [color=red];
|
||||
130 -> {98} [color=green];
|
||||
|
||||
subgraph cluster_26 {
|
||||
color=red
|
||||
131 [label="Enter function test_4" style="filled" fillcolor=red];
|
||||
subgraph cluster_27 {
|
||||
color=blue
|
||||
132 [label="Enter block"];
|
||||
133 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_28 {
|
||||
color=blue
|
||||
152 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_29 {
|
||||
color=blue
|
||||
153 [label="Enter block"];
|
||||
154 [label="Access variable R|<local>/y|"];
|
||||
155 [label="Function call: R|<local>/y|.<Unresolved name: inc>#()"];
|
||||
156 [label="Access variable R|<local>/x|"];
|
||||
157 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
|
||||
158 [label="Exit block"];
|
||||
}
|
||||
159 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
134 [label="Postponed exit from lambda"];
|
||||
135 [label="Function call: R|/myRun|<R|kotlin/Int|>(...)"];
|
||||
136 [label="Function call: R|/id|<R|kotlin/Int|>(...)"];
|
||||
137 [label="Access variable R|<local>/y|"];
|
||||
138 [label="Type operator: (R|<local>/y| as R|kotlin/Int|)"];
|
||||
139 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_30 {
|
||||
color=blue
|
||||
160 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_31 {
|
||||
color=blue
|
||||
161 [label="Enter block"];
|
||||
162 [label="Access variable R|<local>/x|"];
|
||||
163 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
|
||||
164 [label="Access variable R|<local>/y|"];
|
||||
165 [label="Function call: R|<local>/y|.R|kotlin/Int.inc|()"];
|
||||
166 [label="Const: Int(1)"];
|
||||
167 [label="Exit block"];
|
||||
}
|
||||
168 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
140 [label="Postponed exit from lambda"];
|
||||
141 [label="Function call: R|/myRun|<R|kotlin/Int|>(...)"];
|
||||
142 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
143 [label="Variable declaration: lval a: R|kotlin/Int|"];
|
||||
144 [label="Access variable R|<local>/x|"];
|
||||
145 [label="Function call: <Inapplicable(INAPPLICABLE): [/takeInt]>#(...)"];
|
||||
146 [label="Access variable R|<local>/y|"];
|
||||
147 [label="Function call: R|/takeInt|(...)"];
|
||||
148 [label="Access variable R|<local>/a|"];
|
||||
149 [label="Function call: R|/takeInt|(...)"];
|
||||
150 [label="Exit block"];
|
||||
}
|
||||
151 [label="Exit function test_4" style="filled" fillcolor=red];
|
||||
}
|
||||
131 -> {132};
|
||||
132 -> {133};
|
||||
133 -> {134};
|
||||
133 -> {134 152};
|
||||
134 -> {135};
|
||||
135 -> {136};
|
||||
136 -> {131};
|
||||
|
||||
subgraph cluster_16 {
|
||||
color=red
|
||||
137 [label="Enter function test_5" style="filled" fillcolor=red];
|
||||
139 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_17 {
|
||||
color=blue
|
||||
150 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
152 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
151 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
140 [label="Postponed exit from lambda"];
|
||||
141 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
142 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_18 {
|
||||
color=blue
|
||||
153 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
155 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
154 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
143 [label="Postponed exit from lambda"];
|
||||
144 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
146 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
145 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
147 [label="Variable declaration: lval x: R|kotlin/Int|"];
|
||||
148 [label="Access variable R|<local>/x|"];
|
||||
149 [label="Function call: R|/takeInt|(...)"];
|
||||
138 [label="Exit function test_5" style="filled" fillcolor=red];
|
||||
}
|
||||
137 -> {139};
|
||||
139 -> {150};
|
||||
139 -> {140} [color=red];
|
||||
136 -> {137};
|
||||
137 -> {138};
|
||||
138 -> {139};
|
||||
139 -> {140 160};
|
||||
140 -> {141};
|
||||
141 -> {142};
|
||||
142 -> {153};
|
||||
142 -> {143} [color=red];
|
||||
142 -> {143};
|
||||
143 -> {144};
|
||||
144 -> {146};
|
||||
145 -> {147};
|
||||
146 -> {145};
|
||||
144 -> {145};
|
||||
145 -> {146};
|
||||
146 -> {147};
|
||||
147 -> {148};
|
||||
148 -> {149};
|
||||
149 -> {138};
|
||||
150 -> {152};
|
||||
151 -> {140} [color=green];
|
||||
151 -> {146} [color=red];
|
||||
152 -> {151};
|
||||
153 -> {155};
|
||||
154 -> {143} [color=green];
|
||||
154 -> {146} [color=red];
|
||||
155 -> {154};
|
||||
|
||||
subgraph cluster_19 {
|
||||
color=red
|
||||
156 [label="Enter function test_6" style="filled" fillcolor=red];
|
||||
158 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_20 {
|
||||
color=blue
|
||||
163 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
165 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_21 {
|
||||
color=blue
|
||||
168 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
170 [label="Function call: R|/materialize|<R|kotlin/String|>()"];
|
||||
169 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
166 [label="Postponed exit from lambda"];
|
||||
167 [label="Function call: R|kotlin/run|<R|kotlin/String|>(...)"];
|
||||
164 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
159 [label="Postponed exit from lambda"];
|
||||
160 [label="Function call: R|/myRun|<R|kotlin/String|>(...)"];
|
||||
161 [label="Function call: R|/id|<R|kotlin/String|>(...)"];
|
||||
162 [label="Variable declaration: lval x: R|kotlin/String|"];
|
||||
157 [label="Exit function test_6" style="filled" fillcolor=red];
|
||||
}
|
||||
156 -> {158};
|
||||
149 -> {150};
|
||||
150 -> {151};
|
||||
152 -> {153};
|
||||
153 -> {154};
|
||||
154 -> {155};
|
||||
155 -> {156};
|
||||
156 -> {157};
|
||||
157 -> {158};
|
||||
158 -> {159};
|
||||
158 -> {163} [color=red];
|
||||
159 -> {160};
|
||||
160 -> {161};
|
||||
161 -> {162};
|
||||
162 -> {157};
|
||||
163 -> {165};
|
||||
165 -> {168};
|
||||
165 -> {166} [color=red];
|
||||
162 -> {163};
|
||||
163 -> {164};
|
||||
164 -> {165};
|
||||
165 -> {166};
|
||||
166 -> {167};
|
||||
167 -> {164};
|
||||
168 -> {170};
|
||||
169 -> {166} [color=green];
|
||||
170 -> {169};
|
||||
167 -> {168};
|
||||
|
||||
subgraph cluster_32 {
|
||||
color=red
|
||||
169 [label="Enter function test_5" style="filled" fillcolor=red];
|
||||
subgraph cluster_33 {
|
||||
color=blue
|
||||
170 [label="Enter block"];
|
||||
171 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_34 {
|
||||
color=blue
|
||||
184 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_35 {
|
||||
color=blue
|
||||
185 [label="Enter block"];
|
||||
186 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
187 [label="Exit block"];
|
||||
}
|
||||
188 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
172 [label="Postponed exit from lambda"];
|
||||
173 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
174 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_36 {
|
||||
color=blue
|
||||
189 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_37 {
|
||||
color=blue
|
||||
190 [label="Enter block"];
|
||||
191 [label="Function call: R|/materialize|<R|kotlin/Int|>()"];
|
||||
192 [label="Exit block"];
|
||||
}
|
||||
193 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
175 [label="Postponed exit from lambda"];
|
||||
176 [label="Function call: R|kotlin/run|<R|kotlin/Int|>(...)"];
|
||||
177 [label="Call arguments union" style="filled" fillcolor=yellow];
|
||||
178 [label="Function call: R|/select|<R|kotlin/Int|>(...)"];
|
||||
179 [label="Variable declaration: lval x: R|kotlin/Int|"];
|
||||
180 [label="Access variable R|<local>/x|"];
|
||||
181 [label="Function call: R|/takeInt|(...)"];
|
||||
182 [label="Exit block"];
|
||||
}
|
||||
183 [label="Exit function test_5" style="filled" fillcolor=red];
|
||||
}
|
||||
169 -> {170};
|
||||
170 -> {171};
|
||||
171 -> {184};
|
||||
171 -> {172} [color=red];
|
||||
172 -> {173};
|
||||
173 -> {174};
|
||||
174 -> {189};
|
||||
174 -> {175} [color=red];
|
||||
175 -> {176};
|
||||
176 -> {177};
|
||||
177 -> {178};
|
||||
178 -> {179};
|
||||
179 -> {180};
|
||||
180 -> {181};
|
||||
181 -> {182};
|
||||
182 -> {183};
|
||||
184 -> {185};
|
||||
185 -> {186};
|
||||
186 -> {187};
|
||||
187 -> {188};
|
||||
188 -> {177} [color=red];
|
||||
188 -> {172} [color=green];
|
||||
189 -> {190};
|
||||
190 -> {191};
|
||||
191 -> {192};
|
||||
192 -> {193};
|
||||
193 -> {177} [color=red];
|
||||
193 -> {175} [color=green];
|
||||
|
||||
subgraph cluster_38 {
|
||||
color=red
|
||||
194 [label="Enter function test_6" style="filled" fillcolor=red];
|
||||
subgraph cluster_39 {
|
||||
color=blue
|
||||
195 [label="Enter block"];
|
||||
196 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_40 {
|
||||
color=blue
|
||||
203 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_41 {
|
||||
color=blue
|
||||
204 [label="Enter block"];
|
||||
205 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_42 {
|
||||
color=blue
|
||||
210 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_43 {
|
||||
color=blue
|
||||
211 [label="Enter block"];
|
||||
212 [label="Function call: R|/materialize|<R|kotlin/String|>()"];
|
||||
213 [label="Exit block"];
|
||||
}
|
||||
214 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
206 [label="Postponed exit from lambda"];
|
||||
207 [label="Function call: R|kotlin/run|<R|kotlin/String|>(...)"];
|
||||
208 [label="Exit block"];
|
||||
}
|
||||
209 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
197 [label="Postponed exit from lambda"];
|
||||
198 [label="Function call: R|/myRun|<R|kotlin/String|>(...)"];
|
||||
199 [label="Function call: R|/id|<R|kotlin/String|>(...)"];
|
||||
200 [label="Variable declaration: lval x: R|kotlin/String|"];
|
||||
201 [label="Exit block"];
|
||||
}
|
||||
202 [label="Exit function test_6" style="filled" fillcolor=red];
|
||||
}
|
||||
194 -> {195};
|
||||
195 -> {196};
|
||||
196 -> {197 203};
|
||||
197 -> {198};
|
||||
198 -> {199};
|
||||
199 -> {200};
|
||||
200 -> {201};
|
||||
201 -> {202};
|
||||
203 -> {204};
|
||||
204 -> {205};
|
||||
205 -> {210};
|
||||
205 -> {206} [color=red];
|
||||
206 -> {207};
|
||||
207 -> {208};
|
||||
208 -> {209};
|
||||
210 -> {211};
|
||||
211 -> {212};
|
||||
212 -> {213};
|
||||
213 -> {214};
|
||||
214 -> {206} [color=green];
|
||||
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user