FIR DFA: fix CFG with normal arg after lambda [KT-46825]
The fix is a bit hacky, but it's very simple. In addition, it still does not handle the case where the receiver is a lambda function. But such case seems to be fairly rare in practice.
This commit is contained in:
committed by
TeamCityServer
parent
b78b50e1f8
commit
2e049c1208
@@ -24,7 +24,8 @@ digraph postponedLambdas_kt {
|
||||
color=blue
|
||||
5 [label="Enter block"];
|
||||
6 [label="Access variable R|<local>/a|"];
|
||||
7 [label="Postponed enter to lambda"];
|
||||
7 [label="Access variable R|<local>/b|"];
|
||||
8 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_4 {
|
||||
color=blue
|
||||
13 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
@@ -36,8 +37,7 @@ digraph postponedLambdas_kt {
|
||||
}
|
||||
17 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
8 [label="Postponed exit from lambda"];
|
||||
9 [label="Access variable R|<local>/b|"];
|
||||
9 [label="Postponed exit from lambda"];
|
||||
10 [label="Function call: R|/foo|(...)"];
|
||||
11 [label="Exit block"];
|
||||
}
|
||||
@@ -46,10 +46,10 @@ digraph postponedLambdas_kt {
|
||||
4 -> {5};
|
||||
5 -> {6};
|
||||
6 -> {7};
|
||||
7 -> {13};
|
||||
7 -> {8} [color=red];
|
||||
7 -> {13} [style=dashed];
|
||||
8 -> {9};
|
||||
7 -> {8};
|
||||
8 -> {13};
|
||||
8 -> {9} [color=red];
|
||||
8 -> {13} [style=dashed];
|
||||
9 -> {10};
|
||||
10 -> {11};
|
||||
11 -> {12};
|
||||
@@ -57,7 +57,7 @@ digraph postponedLambdas_kt {
|
||||
14 -> {15};
|
||||
15 -> {16};
|
||||
16 -> {17};
|
||||
17 -> {8} [color=green];
|
||||
17 -> {9} [color=green];
|
||||
17 -> {13} [color=green style=dashed];
|
||||
|
||||
}
|
||||
|
||||
Vendored
+20
-20
@@ -262,22 +262,9 @@ digraph callsInPlace_kt {
|
||||
86 [label="Enter block"];
|
||||
87 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_24 {
|
||||
color=blue
|
||||
94 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
95 [label="Enter block"];
|
||||
96 [label="Const: String(test_6_1)"];
|
||||
97 [label="Exit block"];
|
||||
}
|
||||
98 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
88 [label="Postponed exit from lambda"];
|
||||
89 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_26 {
|
||||
color=blue
|
||||
99 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_27 {
|
||||
subgraph cluster_25 {
|
||||
color=blue
|
||||
100 [label="Enter block"];
|
||||
101 [label="Const: String(test_6_2)"];
|
||||
@@ -285,6 +272,19 @@ digraph callsInPlace_kt {
|
||||
}
|
||||
103 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
88 [label="Postponed exit from lambda"];
|
||||
89 [label="Postponed enter to lambda"];
|
||||
subgraph cluster_26 {
|
||||
color=blue
|
||||
94 [label="Enter function anonymousFunction" style="filled" fillcolor=red];
|
||||
subgraph cluster_27 {
|
||||
color=blue
|
||||
95 [label="Enter block"];
|
||||
96 [label="Const: String(test_6_1)"];
|
||||
97 [label="Exit block"];
|
||||
}
|
||||
98 [label="Exit function anonymousFunction" style="filled" fillcolor=red];
|
||||
}
|
||||
90 [label="Postponed exit from lambda"];
|
||||
91 [label="Function call: R|/myRun|(...)"];
|
||||
92 [label="Exit block"];
|
||||
@@ -293,13 +293,13 @@ digraph callsInPlace_kt {
|
||||
}
|
||||
85 -> {86};
|
||||
86 -> {87};
|
||||
87 -> {94};
|
||||
87 -> {99};
|
||||
87 -> {88} [color=red];
|
||||
87 -> {94} [style=dashed];
|
||||
87 -> {99} [style=dashed];
|
||||
88 -> {89};
|
||||
89 -> {99};
|
||||
89 -> {94};
|
||||
89 -> {90} [color=red];
|
||||
89 -> {99} [style=dashed];
|
||||
89 -> {94} [style=dashed];
|
||||
90 -> {91};
|
||||
91 -> {92};
|
||||
92 -> {93};
|
||||
@@ -307,13 +307,13 @@ digraph callsInPlace_kt {
|
||||
95 -> {96};
|
||||
96 -> {97};
|
||||
97 -> {98};
|
||||
98 -> {88} [color=green];
|
||||
98 -> {90} [color=green];
|
||||
98 -> {94} [color=green style=dashed];
|
||||
99 -> {103 100};
|
||||
100 -> {101};
|
||||
101 -> {102};
|
||||
102 -> {103};
|
||||
103 -> {90} [color=green];
|
||||
103 -> {88} [color=green];
|
||||
103 -> {99} [color=green style=dashed];
|
||||
|
||||
subgraph cluster_28 {
|
||||
|
||||
Reference in New Issue
Block a user