Files
kotlin-fork/compiler/fir/analysis-tests/testData/resolve/smartcasts/safeCalls/assignSafeCall.dot
T

419 lines
13 KiB
Plaintext
Vendored

digraph assignSafeCall_kt {
graph [nodesep=3]
node [shape=box penwidth=2]
edge [penwidth=2]
subgraph cluster_0 {
color=red
0 [label="Enter function <init>" style="filled" fillcolor=red];
1 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
2 [label="Exit function <init>" style="filled" fillcolor=red];
}
0 -> {1};
1 -> {2};
subgraph cluster_1 {
color=red
3 [label="Enter function foo" style="filled" fillcolor=red];
subgraph cluster_2 {
color=blue
4 [label="Enter block"];
5 [label="Const: Int(1)"];
6 [label="Jump: ^foo Int(1)"];
7 [label="Stub" style="filled" fillcolor=gray];
8 [label="Exit block" style="filled" fillcolor=gray];
}
9 [label="Exit function foo" style="filled" fillcolor=red];
}
3 -> {4};
4 -> {5};
5 -> {6};
6 -> {9};
6 -> {7} [style=dotted];
7 -> {8} [style=dotted];
8 -> {9} [style=dotted];
subgraph cluster_3 {
color=red
10 [label="Enter property" style="filled" fillcolor=red];
11 [label="Const: Int(1)"];
12 [label="Exit property" style="filled" fillcolor=red];
}
10 -> {11};
11 -> {12};
12 -> {19} [color=green];
subgraph cluster_4 {
color=red
13 [label="Enter function bar" style="filled" fillcolor=red];
subgraph cluster_5 {
color=blue
14 [label="Enter block"];
15 [label="Exit block"];
}
16 [label="Exit function bar" style="filled" fillcolor=red];
}
13 -> {14};
14 -> {15};
15 -> {16};
subgraph cluster_6 {
color=red
17 [label="Enter class A" style="filled" fillcolor=red];
18 [label="Part of class initialization"];
19 [label="Exit class A" style="filled" fillcolor=red];
}
17 -> {18} [color=green];
18 -> {19} [style=dotted];
18 -> {10} [color=green];
18 -> {10} [style=dashed];
subgraph cluster_7 {
color=red
20 [label="Enter function test_1" style="filled" fillcolor=red];
subgraph cluster_8 {
color=blue
21 [label="Enter block"];
22 [label="Access variable R|<local>/a|"];
23 [label="Enter safe call"];
24 [label="Access variable R|/A.x|"];
25 [label="Exit safe call"];
26 [label="Variable declaration: lval x: R|kotlin/Int?|"];
subgraph cluster_9 {
color=blue
27 [label="Enter when"];
subgraph cluster_10 {
color=blue
28 [label="Enter when branch condition "];
29 [label="Access variable R|<local>/x|"];
30 [label="Const: Null(null)"];
31 [label="Equality operator !="];
32 [label="Exit when branch condition"];
}
33 [label="Synthetic else branch"];
34 [label="Enter when branch result"];
subgraph cluster_11 {
color=blue
35 [label="Enter block"];
36 [label="Access variable R|<local>/a|"];
37 [label="Function call: R|<local>/a|.R|/A.bar|()"];
38 [label="Exit block"];
}
39 [label="Exit when branch result"];
40 [label="Exit when"];
}
41 [label="Exit block"];
}
42 [label="Exit function test_1" style="filled" fillcolor=red];
}
20 -> {21};
21 -> {22};
22 -> {23 25};
23 -> {24};
24 -> {25};
25 -> {26};
26 -> {27};
27 -> {28};
28 -> {29};
29 -> {30};
30 -> {31};
31 -> {32};
32 -> {34 33};
33 -> {40};
34 -> {35};
35 -> {36};
36 -> {37};
37 -> {38};
38 -> {39};
39 -> {40};
40 -> {41};
41 -> {42};
subgraph cluster_12 {
color=red
43 [label="Enter function test_2" style="filled" fillcolor=red];
subgraph cluster_13 {
color=blue
44 [label="Enter block"];
45 [label="Access variable R|<local>/a|"];
46 [label="Enter safe call"];
47 [label="Function call: $subj$.R|/A.foo|()"];
48 [label="Exit safe call"];
49 [label="Variable declaration: lval x: R|kotlin/Int?|"];
subgraph cluster_14 {
color=blue
50 [label="Enter when"];
subgraph cluster_15 {
color=blue
51 [label="Enter when branch condition "];
52 [label="Access variable R|<local>/x|"];
53 [label="Const: Null(null)"];
54 [label="Equality operator !="];
55 [label="Exit when branch condition"];
}
56 [label="Synthetic else branch"];
57 [label="Enter when branch result"];
subgraph cluster_16 {
color=blue
58 [label="Enter block"];
59 [label="Access variable R|<local>/a|"];
60 [label="Function call: R|<local>/a|.R|/A.bar|()"];
61 [label="Exit block"];
}
62 [label="Exit when branch result"];
63 [label="Exit when"];
}
64 [label="Exit block"];
}
65 [label="Exit function test_2" style="filled" fillcolor=red];
}
43 -> {44};
44 -> {45};
45 -> {46 48};
46 -> {47};
47 -> {48};
48 -> {49};
49 -> {50};
50 -> {51};
51 -> {52};
52 -> {53};
53 -> {54};
54 -> {55};
55 -> {57 56};
56 -> {63};
57 -> {58};
58 -> {59};
59 -> {60};
60 -> {61};
61 -> {62};
62 -> {63};
63 -> {64};
64 -> {65};
subgraph cluster_17 {
color=red
66 [label="Enter function test_3" style="filled" fillcolor=red];
subgraph cluster_18 {
color=blue
67 [label="Enter block"];
68 [label="Access variable R|<local>/x|"];
69 [label="Type operator: (R|<local>/x| as? R|A|)"];
70 [label="Exit lhs of ?:"];
71 [label="Enter rhs of ?:"];
72 [label="Jump: ^test_3 Unit"];
73 [label="Stub" style="filled" fillcolor=gray];
74 [label="Lhs of ?: is not null"];
75 [label="Exit ?:"];
76 [label="Variable declaration: lval a: R|A|"];
77 [label="Access variable R|<local>/a|"];
78 [label="Function call: R|<local>/a|.R|/A.foo|()"];
79 [label="Access variable R|<local>/x|"];
80 [label="Function call: R|<local>/x|.R|/A.foo|()"];
81 [label="Exit block"];
}
82 [label="Exit function test_3" style="filled" fillcolor=red];
}
66 -> {67};
67 -> {68};
68 -> {69};
69 -> {70};
70 -> {74 71};
71 -> {72};
72 -> {82};
72 -> {73} [style=dotted];
73 -> {75} [style=dotted];
74 -> {75};
75 -> {76};
76 -> {77};
77 -> {78};
78 -> {79};
79 -> {80};
80 -> {81};
81 -> {82};
subgraph cluster_19 {
color=red
83 [label="Enter function foo" style="filled" fillcolor=red];
84 [label="Exit function foo" style="filled" fillcolor=red];
}
83 -> {84};
subgraph cluster_20 {
color=red
85 [label="Enter function bar" style="filled" fillcolor=red];
86 [label="Exit function bar" style="filled" fillcolor=red];
}
85 -> {86};
subgraph cluster_21 {
color=red
87 [label="Enter class B" style="filled" fillcolor=red];
88 [label="Exit class B" style="filled" fillcolor=red];
}
87 -> {88} [color=green];
subgraph cluster_22 {
color=red
89 [label="Enter function test_1" style="filled" fillcolor=red];
subgraph cluster_23 {
color=blue
90 [label="Enter block"];
91 [label="Access variable R|<local>/a|"];
92 [label="Enter safe call"];
93 [label="Access variable R|/B.x|"];
94 [label="Exit safe call"];
95 [label="Variable declaration: lval x: R|kotlin/Int?|"];
subgraph cluster_24 {
color=blue
96 [label="Enter when"];
subgraph cluster_25 {
color=blue
97 [label="Enter when branch condition "];
98 [label="Access variable R|<local>/x|"];
99 [label="Const: Null(null)"];
100 [label="Equality operator !="];
101 [label="Exit when branch condition"];
}
102 [label="Synthetic else branch"];
103 [label="Enter when branch result"];
subgraph cluster_26 {
color=blue
104 [label="Enter block"];
105 [label="Access variable R|<local>/a|"];
106 [label="Function call: R|<local>/a|.R|/B.bar|()"];
107 [label="Exit block"];
}
108 [label="Exit when branch result"];
109 [label="Exit when"];
}
110 [label="Exit block"];
}
111 [label="Exit function test_1" style="filled" fillcolor=red];
}
89 -> {90};
90 -> {91};
91 -> {92 94};
92 -> {93};
93 -> {94};
94 -> {95};
95 -> {96};
96 -> {97};
97 -> {98};
98 -> {99};
99 -> {100};
100 -> {101};
101 -> {103 102};
102 -> {109};
103 -> {104};
104 -> {105};
105 -> {106};
106 -> {107};
107 -> {108};
108 -> {109};
109 -> {110};
110 -> {111};
subgraph cluster_27 {
color=red
112 [label="Enter function test_2" style="filled" fillcolor=red];
subgraph cluster_28 {
color=blue
113 [label="Enter block"];
114 [label="Access variable R|<local>/a|"];
115 [label="Enter safe call"];
116 [label="Function call: $subj$.R|/B.foo|()"];
117 [label="Exit safe call"];
118 [label="Variable declaration: lval x: R|kotlin/Int?|"];
subgraph cluster_29 {
color=blue
119 [label="Enter when"];
subgraph cluster_30 {
color=blue
120 [label="Enter when branch condition "];
121 [label="Access variable R|<local>/x|"];
122 [label="Const: Null(null)"];
123 [label="Equality operator !="];
124 [label="Exit when branch condition"];
}
125 [label="Synthetic else branch"];
126 [label="Enter when branch result"];
subgraph cluster_31 {
color=blue
127 [label="Enter block"];
128 [label="Access variable R|<local>/a|"];
129 [label="Function call: R|<local>/a|.R|/B.bar|()"];
130 [label="Exit block"];
}
131 [label="Exit when branch result"];
132 [label="Exit when"];
}
133 [label="Exit block"];
}
134 [label="Exit function test_2" style="filled" fillcolor=red];
}
112 -> {113};
113 -> {114};
114 -> {115 117};
115 -> {116};
116 -> {117};
117 -> {118};
118 -> {119};
119 -> {120};
120 -> {121};
121 -> {122};
122 -> {123};
123 -> {124};
124 -> {126 125};
125 -> {132};
126 -> {127};
127 -> {128};
128 -> {129};
129 -> {130};
130 -> {131};
131 -> {132};
132 -> {133};
133 -> {134};
subgraph cluster_32 {
color=red
135 [label="Enter function test_3" style="filled" fillcolor=red];
subgraph cluster_33 {
color=blue
136 [label="Enter block"];
137 [label="Access variable R|<local>/x|"];
138 [label="Type operator: (R|<local>/x| as? R|B|)"];
139 [label="Exit lhs of ?:"];
140 [label="Enter rhs of ?:"];
141 [label="Jump: ^test_3 Unit"];
142 [label="Stub" style="filled" fillcolor=gray];
143 [label="Lhs of ?: is not null"];
144 [label="Exit ?:"];
145 [label="Variable declaration: lval a: R|B|"];
146 [label="Access variable R|<local>/a|"];
147 [label="Function call: R|<local>/a|.R|/B.foo|()"];
148 [label="Access variable R|<local>/x|"];
149 [label="Function call: R|<local>/x|.R|/B.foo|()"];
150 [label="Exit block"];
}
151 [label="Exit function test_3" style="filled" fillcolor=red];
}
135 -> {136};
136 -> {137};
137 -> {138};
138 -> {139};
139 -> {143 140};
140 -> {141};
141 -> {151};
141 -> {142} [style=dotted];
142 -> {144} [style=dotted];
143 -> {144};
144 -> {145};
145 -> {146};
146 -> {147};
147 -> {148};
148 -> {149};
149 -> {150};
150 -> {151};
}