FIR CFA: rewrite handling of try-catch-finally

The result is the same, but it should now be much clearer what the
shortcomings of the current implementation are.
This commit is contained in:
pyos
2022-11-27 21:27:37 +01:00
committed by Dmitriy Novozhilov
parent a079010fad
commit 069d99c5ea
10 changed files with 390 additions and 466 deletions
+18 -18
View File
@@ -190,19 +190,19 @@ digraph jumps_kt {
68 [label="Access variable R|<local>/x|"];
69 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
70 [label="Jump: break@@@[Boolean(true)] "];
71 [label="Stub" style="filled" fillcolor=gray];
72 [label="Exit block" style="filled" fillcolor=gray];
77 [label="Stub" style="filled" fillcolor=gray];
78 [label="Exit block" style="filled" fillcolor=gray];
}
73 [label="Exit loop block" style="filled" fillcolor=gray];
79 [label="Exit loop block" style="filled" fillcolor=gray];
}
74 [label="Exit whileloop"];
71 [label="Exit whileloop"];
}
75 [label="Access variable R|<local>/x|"];
76 [label="Smart cast: R|<local>/x|"];
77 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow];
78 [label="Exit block"];
72 [label="Access variable R|<local>/x|"];
73 [label="Smart cast: R|<local>/x|"];
74 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow];
75 [label="Exit block"];
}
79 [label="Exit function test_3" style="filled" fillcolor=red];
76 [label="Exit function test_3" style="filled" fillcolor=red];
}
60 -> {61};
61 -> {62};
@@ -210,21 +210,21 @@ digraph jumps_kt {
63 -> {64};
64 -> {65};
65 -> {66};
65 -> {74} [style=dotted];
65 -> {71} [style=dotted];
66 -> {67};
67 -> {68};
68 -> {69};
69 -> {70};
70 -> {74};
70 -> {71} [style=dotted];
71 -> {72} [style=dotted];
72 -> {73} [style=dotted];
73 -> {63} [color=green style=dotted];
70 -> {71};
70 -> {77} [style=dotted];
71 -> {72};
72 -> {73};
73 -> {74};
74 -> {75};
75 -> {76};
76 -> {77};
77 -> {78};
78 -> {79};
77 -> {78} [style=dotted];
78 -> {79} [style=dotted];
79 -> {63} [color=green style=dotted];
subgraph cluster_20 {
color=red