From b2041e092737fa349f60002820ab5d21222e3062 Mon Sep 17 00:00:00 2001 From: Brian Norman Date: Mon, 11 Dec 2023 10:25:48 -0600 Subject: [PATCH] [FIR] Disable data flow from in-place lambdas There are many complications with the current design of passing data from within in-place lambdas to surrounding code. Solving these complications will involve more time to investigation than is available within the K2 release. So we are disabling passing type statement information from lambdas for the time being until more time can be devoted to a more complete solution. ^KT-60958 Fixed ^KT-63530 Fixed --- .../testData/resolve/cfg/defaultArguments.dot | 2 +- .../resolve/cfg/flowFromInplaceLambda.dot | 2486 ++++++++--------- .../resolve/cfg/flowFromInplaceLambda.fir.txt | 14 +- .../resolve/cfg/flowFromInplaceLambda.kt | 14 +- .../resolve/cfg/flowFromInplaceLambda2.dot | 1072 ++++--- .../cfg/flowFromInplaceLambda2.fir.txt | 6 +- .../resolve/cfg/flowFromInplaceLambda2.kt | 8 +- .../resolve/cfg/flowFromInplaceLambda3.dot | 400 ++- .../cfg/flowFromInplaceLambda3.fir.txt | 6 +- .../resolve/cfg/flowFromInplaceLambda3.kt | 6 +- .../resolve/cfg/flowFromTwoInplaceLambdas.dot | 880 +++--- .../cfg/flowFromTwoInplaceLambdas.fir.txt | 12 +- .../resolve/cfg/flowFromTwoInplaceLambdas.kt | 12 +- .../resolve/cfg/initBlockAndInPlaceLambda.dot | 2 +- .../inplaceLambdaInControlFlowExpressions.dot | 6 +- .../testData/resolve/cfg/jumps.dot | 2 +- .../resolve/cfg/lambdaAsReturnOfLambda.dot | 2 +- .../resolve/cfg/lambdaReturningObject.dot | 2 +- .../testData/resolve/cfg/lambdas.dot | 6 +- .../resolve/cfg/localClassesWithImplicit.dot | 8 +- .../cfg/postponedLambdaInConstructor.dot | 2 +- .../resolve/cfg/postponedLambdaInReturn.dot | 6 +- .../testData/resolve/cfg/postponedLambdas.dot | 2 +- .../resolve/cfg/propertiesAndInitBlocks.dot | 2 +- .../resolve/cfg/returnValuesFromLambda.dot | 6 +- .../testData/resolve/classCallInLambda.dot | 2 +- .../smartcasts/controlStructures/returns.dot | 2 +- .../incorrectSmartcastToNothing.dot | 2 +- .../smartcasts/lambdas/inPlaceLambdas.dot | 108 +- .../smartcasts/lambdas/inPlaceLambdas.fir.txt | 4 +- .../smartcasts/lambdas/inPlaceLambdas.kt | 4 +- .../smartcasts/lambdas/lambdaInWhenBranch.dot | 2 +- .../receivers/implicitReceivers.dot | 366 ++- .../receivers/implicitReceivers.fir.txt | 8 +- .../smartcasts/receivers/implicitReceivers.kt | 6 +- .../smartcasts/safeCalls/safeCalls.dot | 4 +- .../resolve/smartcasts/smartcastToNothing.dot | 2 +- .../resolveWithStdlib/complexPostponedCfg.dot | 6 +- .../contracts/fromLibrary/callsInPlace.dot | 20 +- .../good/callsInPlace/atLeastOnce.dot | 4 +- .../good/callsInPlace/atMostOnce.dot | 4 +- .../good/callsInPlace/exactlyOnce.dot | 4 +- .../good/callsInPlace/inPlaceLambda.dot | 2 +- .../fromSource/good/callsInPlace/unknown.dot | 4 +- .../delegates/delegateWithAnonymousObject.dot | 2 +- .../inference/plusAssignWithLambdaInRhs.dot | 6 +- .../smartcasts/tryWithLambdaInside.dot | 4 +- .../util/PathAwareControlFlowGraphVisitor.kt | 3 +- .../fir/resolve/dfa/FirDataFlowAnalyzer.kt | 44 +- .../dfa/cfg/ControlFlowGraphBuilder.kt | 4 +- .../kotlin/fir/resolve/dfa/LogicSystem.kt | 12 +- .../fir/resolve/dfa/cfg/ControlFlowGraph.kt | 4 + .../codegen/box/smartCasts/kt44814.dot | 4 +- .../definiteReturn/singleReturnFromTry.dot | 8 +- .../delegatedConstructorArguments.dot | 4 +- .../controlFlowAnalysis/smartCastInCatch.dot | 2 +- .../castchecks/castInTryWithJump.dot | 2 +- .../ownerDeclaresBothModifies.fir.kt | 4 +- .../capturingInInitializer.fir.kt | 4 +- ...rtCastOnValueBoundToSubjectVariable.fir.kt | 48 - .../smartCastOnValueBoundToSubjectVariable.kt | 10 +- .../contracts/fromStdlib/require.fir.kt | 27 - .../contracts/fromStdlib/require.kt | 35 +- .../contracts/fromStdlib/require.txt | 7 - .../letAlwaysChangesToNotNull.fir.kt | 2 +- .../smartcasts/letMergeNotNull.fir.kt | 2 +- .../analysis/smartcasts/pos/12.fir.kt | 39 - .../contracts/analysis/smartcasts/pos/12.kt | 1 + 68 files changed, 2834 insertions(+), 2962 deletions(-) delete mode 100644 compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.fir.kt delete mode 100644 compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.fir.kt delete mode 100644 compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.txt delete mode 100644 compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.fir.kt diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot index c9b3e12bbc1..b1463a4530d 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/defaultArguments.dot @@ -110,7 +110,7 @@ digraph defaultArguments_kt { 25 -> {26}; 26 -> {28}; 27 -> {29}; - 28 -> {29}; + 28 -> {29} [label="Postponed"]; 29 -> {30}; 30 -> {31}; 31 -> {32}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.dot index db32b1aad0a..6617583753e 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.dot @@ -285,13 +285,12 @@ digraph flowFromInplaceLambda_kt { color=blue 95 [label="Function call arguments enter"]; 96 [label="Access variable R|/x|"]; - 97 [label="Smart cast: R|/x|"]; - 98 [label="Function call arguments exit"]; + 97 [label="Function call arguments exit"]; } - 99 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 100 [label="Exit block"]; + 98 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 99 [label="Exit block"]; } - 101 [label="Exit function basic" style="filled" fillcolor=red]; + 100 [label="Exit function basic" style="filled" fillcolor=red]; } 82 -> {83}; 83 -> {84}; @@ -306,131 +305,130 @@ digraph flowFromInplaceLambda_kt { 90 -> {91}; 91 -> {93}; 92 -> {94}; - 93 -> {94}; + 93 -> {94} [label="Postponed"]; 94 -> {95}; 95 -> {96}; 96 -> {97}; 97 -> {98}; 98 -> {99}; 99 -> {100}; - 100 -> {101}; subgraph cluster_33 { color=red - 102 [label="Enter function completedCallExactlyOnce" style="filled" fillcolor=red]; + 101 [label="Enter function completedCallExactlyOnce" style="filled" fillcolor=red]; subgraph cluster_34 { color=blue - 103 [label="Enter block"]; + 102 [label="Enter block"]; subgraph cluster_35 { color=blue - 104 [label="Function call arguments enter"]; + 103 [label="Function call arguments enter"]; subgraph cluster_36 { color=blue - 105 [label="Function call arguments enter"]; + 104 [label="Function call arguments enter"]; subgraph cluster_37 { color=blue - 106 [label="Function call arguments enter"]; + 105 [label="Function call arguments enter"]; subgraph cluster_38 { color=blue - 107 [label="Function call arguments enter"]; - 108 [label="Postponed enter to lambda"]; + 106 [label="Function call arguments enter"]; + 107 [label="Postponed enter to lambda"]; subgraph cluster_39 { color=blue - 109 [label="Enter function " style="filled" fillcolor=red]; + 108 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_40 { color=blue - 110 [label="Enter block"]; + 109 [label="Enter block"]; subgraph cluster_41 { color=blue - 111 [label="Function call arguments enter"]; - 112 [label="Access variable R|/y|"]; - 113 [label="Function call arguments exit"]; + 110 [label="Function call arguments enter"]; + 111 [label="Access variable R|/y|"]; + 112 [label="Function call arguments exit"]; } - 114 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 115 [label="Access variable R|/x|"]; - 116 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - 117 [label="Exit block"]; + 113 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 114 [label="Access variable R|/x|"]; + 115 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 116 [label="Exit block"]; } - 118 [label="Exit function " style="filled" fillcolor=red]; + 117 [label="Exit function " style="filled" fillcolor=red]; } - 119 [label="Function call arguments exit"]; + 118 [label="Function call arguments exit"]; } - 120 [label="Postponed exit from lambda"]; - 121 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; - 122 [label="Function call arguments exit"]; + 119 [label="Postponed exit from lambda"]; + 120 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; + 121 [label="Function call arguments exit"]; } - 123 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 124 [label="Access variable R|/y|"]; - 125 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 122 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 123 [label="Access variable R|/y|"]; + 124 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_42 { color=blue - 126 [label="Function call arguments enter"]; - 127 [label="Postponed enter to lambda"]; + 125 [label="Function call arguments enter"]; + 126 [label="Postponed enter to lambda"]; subgraph cluster_43 { color=blue - 128 [label="Enter function " style="filled" fillcolor=red]; + 127 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_44 { color=blue - 129 [label="Enter block"]; + 128 [label="Enter block"]; subgraph cluster_45 { color=blue - 130 [label="Function call arguments enter"]; - 131 [label="Access variable R|/x|"]; - 132 [label="Function call arguments exit"]; + 129 [label="Function call arguments enter"]; + 130 [label="Access variable R|/x|"]; + 131 [label="Function call arguments exit"]; } - 133 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 132 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_46 { color=blue - 134 [label="Function call arguments enter"]; - 135 [label="Access variable R|/y|"]; - 136 [label="Smart cast: R|/y|"]; - 137 [label="Function call arguments exit"]; + 133 [label="Function call arguments enter"]; + 134 [label="Access variable R|/y|"]; + 135 [label="Smart cast: R|/y|"]; + 136 [label="Function call arguments exit"]; } - 138 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 139 [label="Const: Int(1)"]; - 140 [label="Exit block"]; + 137 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 138 [label="Const: Int(1)"]; + 139 [label="Exit block"]; } - 141 [label="Exit function " style="filled" fillcolor=red]; + 140 [label="Exit function " style="filled" fillcolor=red]; } - 142 [label="Function call arguments exit"]; + 141 [label="Function call arguments exit"]; } - 143 [label="Postponed exit from lambda"]; - 144 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; - 145 [label="Function call arguments exit"]; + 142 [label="Postponed exit from lambda"]; + 143 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; + 144 [label="Function call arguments exit"]; } - 146 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 147 [label="Function call arguments exit"]; + 145 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 146 [label="Function call arguments exit"]; } - 148 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 147 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_47 { color=blue - 149 [label="Function call arguments enter"]; - 150 [label="Access variable R|/x|"]; - 151 [label="Smart cast: R|/x|"]; - 152 [label="Function call arguments exit"]; + 148 [label="Function call arguments enter"]; + 149 [label="Access variable R|/x|"]; + 150 [label="Function call arguments exit"]; } - 153 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 151 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_48 { color=blue - 154 [label="Function call arguments enter"]; - 155 [label="Access variable R|/y|"]; - 156 [label="Smart cast: R|/y|"]; - 157 [label="Function call arguments exit"]; + 152 [label="Function call arguments enter"]; + 153 [label="Access variable R|/y|"]; + 154 [label="Smart cast: R|/y|"]; + 155 [label="Function call arguments exit"]; } - 158 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 159 [label="Exit block"]; + 156 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 157 [label="Exit block"]; } - 160 [label="Exit function completedCallExactlyOnce" style="filled" fillcolor=red]; + 158 [label="Exit function completedCallExactlyOnce" style="filled" fillcolor=red]; } + 101 -> {102}; 102 -> {103}; 103 -> {104}; 104 -> {105}; 105 -> {106}; 106 -> {107}; - 107 -> {108}; - 108 -> {109 119}; - 108 -> {120} [style=dotted]; - 108 -> {109} [style=dashed]; + 107 -> {108 118}; + 107 -> {119} [style=dotted]; + 107 -> {108} [style=dashed]; + 108 -> {109}; 109 -> {110}; 110 -> {111}; 111 -> {112}; @@ -439,20 +437,20 @@ digraph flowFromInplaceLambda_kt { 114 -> {115}; 115 -> {116}; 116 -> {117}; - 117 -> {118}; + 117 -> {119}; 118 -> {120}; - 119 -> {121}; - 120 -> {121} [color=green]; - 120 -> {146} [color=red]; + 119 -> {120} [color=green]; + 119 -> {145} [color=red label="Postponed"]; + 120 -> {121}; 121 -> {122}; 122 -> {123}; 123 -> {124}; 124 -> {125}; 125 -> {126}; - 126 -> {127}; - 127 -> {128 142}; - 127 -> {143} [style=dotted]; - 127 -> {128} [style=dashed]; + 126 -> {127 141}; + 126 -> {142} [style=dotted]; + 126 -> {127} [style=dashed]; + 127 -> {128}; 128 -> {129}; 129 -> {130}; 130 -> {131}; @@ -465,11 +463,11 @@ digraph flowFromInplaceLambda_kt { 137 -> {138}; 138 -> {139}; 139 -> {140}; - 140 -> {141}; + 140 -> {142}; 141 -> {143}; - 142 -> {144}; - 143 -> {144} [color=green]; - 143 -> {146} [color=red]; + 142 -> {143} [color=green]; + 142 -> {145} [color=red label="Postponed"]; + 143 -> {144}; 144 -> {145}; 145 -> {146}; 146 -> {147}; @@ -484,125 +482,124 @@ digraph flowFromInplaceLambda_kt { 155 -> {156}; 156 -> {157}; 157 -> {158}; - 158 -> {159}; - 159 -> {160}; subgraph cluster_49 { color=red - 161 [label="Enter function completedCallAtLeastOnce" style="filled" fillcolor=red]; + 159 [label="Enter function completedCallAtLeastOnce" style="filled" fillcolor=red]; subgraph cluster_50 { color=blue - 162 [label="Enter block"]; + 160 [label="Enter block"]; subgraph cluster_51 { color=blue - 163 [label="Function call arguments enter"]; + 161 [label="Function call arguments enter"]; subgraph cluster_52 { color=blue - 164 [label="Function call arguments enter"]; + 162 [label="Function call arguments enter"]; subgraph cluster_53 { color=blue - 165 [label="Function call arguments enter"]; + 163 [label="Function call arguments enter"]; subgraph cluster_54 { color=blue - 166 [label="Function call arguments enter"]; - 167 [label="Postponed enter to lambda"]; + 164 [label="Function call arguments enter"]; + 165 [label="Postponed enter to lambda"]; subgraph cluster_55 { color=blue - 168 [label="Enter function " style="filled" fillcolor=red]; + 166 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_56 { color=blue - 169 [label="Enter block"]; + 167 [label="Enter block"]; subgraph cluster_57 { color=blue - 170 [label="Function call arguments enter"]; - 171 [label="Access variable R|/y|"]; - 172 [label="Function call arguments exit"]; + 168 [label="Function call arguments enter"]; + 169 [label="Access variable R|/y|"]; + 170 [label="Function call arguments exit"]; } - 173 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 174 [label="Access variable R|/x|"]; - 175 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - 176 [label="Exit block"]; + 171 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 172 [label="Access variable R|/x|"]; + 173 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 174 [label="Exit block"]; } - 177 [label="Exit function " style="filled" fillcolor=red]; + 175 [label="Exit function " style="filled" fillcolor=red]; } - 178 [label="Function call arguments exit"]; + 176 [label="Function call arguments exit"]; } - 179 [label="Postponed exit from lambda"]; - 180 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; - 181 [label="Function call arguments exit"]; + 177 [label="Postponed exit from lambda"]; + 178 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; + 179 [label="Function call arguments exit"]; } - 182 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 183 [label="Access variable R|/y|"]; - 184 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 180 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 181 [label="Access variable R|/y|"]; + 182 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_58 { color=blue - 185 [label="Function call arguments enter"]; - 186 [label="Postponed enter to lambda"]; + 183 [label="Function call arguments enter"]; + 184 [label="Postponed enter to lambda"]; subgraph cluster_59 { color=blue - 187 [label="Enter function " style="filled" fillcolor=red]; + 185 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_60 { color=blue - 188 [label="Enter block"]; + 186 [label="Enter block"]; subgraph cluster_61 { color=blue - 189 [label="Function call arguments enter"]; - 190 [label="Access variable R|/x|"]; - 191 [label="Function call arguments exit"]; + 187 [label="Function call arguments enter"]; + 188 [label="Access variable R|/x|"]; + 189 [label="Function call arguments exit"]; } - 192 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 190 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_62 { color=blue - 193 [label="Function call arguments enter"]; - 194 [label="Access variable R|/y|"]; - 195 [label="Smart cast: R|/y|"]; - 196 [label="Function call arguments exit"]; + 191 [label="Function call arguments enter"]; + 192 [label="Access variable R|/y|"]; + 193 [label="Smart cast: R|/y|"]; + 194 [label="Function call arguments exit"]; } - 197 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 198 [label="Const: Int(1)"]; - 199 [label="Exit block"]; + 195 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 196 [label="Const: Int(1)"]; + 197 [label="Exit block"]; } - 200 [label="Exit function " style="filled" fillcolor=red]; + 198 [label="Exit function " style="filled" fillcolor=red]; } - 201 [label="Function call arguments exit"]; + 199 [label="Function call arguments exit"]; } - 202 [label="Postponed exit from lambda"]; - 203 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; - 204 [label="Function call arguments exit"]; + 200 [label="Postponed exit from lambda"]; + 201 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; + 202 [label="Function call arguments exit"]; } - 205 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 206 [label="Function call arguments exit"]; + 203 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 204 [label="Function call arguments exit"]; } - 207 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 205 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_63 { color=blue - 208 [label="Function call arguments enter"]; - 209 [label="Access variable R|/x|"]; - 210 [label="Smart cast: R|/x|"]; - 211 [label="Function call arguments exit"]; + 206 [label="Function call arguments enter"]; + 207 [label="Access variable R|/x|"]; + 208 [label="Function call arguments exit"]; } - 212 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 209 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_64 { color=blue - 213 [label="Function call arguments enter"]; - 214 [label="Access variable R|/y|"]; - 215 [label="Smart cast: R|/y|"]; - 216 [label="Function call arguments exit"]; + 210 [label="Function call arguments enter"]; + 211 [label="Access variable R|/y|"]; + 212 [label="Smart cast: R|/y|"]; + 213 [label="Function call arguments exit"]; } - 217 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 218 [label="Exit block"]; + 214 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 215 [label="Exit block"]; } - 219 [label="Exit function completedCallAtLeastOnce" style="filled" fillcolor=red]; + 216 [label="Exit function completedCallAtLeastOnce" style="filled" fillcolor=red]; } + 159 -> {160}; + 160 -> {161}; 161 -> {162}; 162 -> {163}; 163 -> {164}; 164 -> {165}; - 165 -> {166}; + 165 -> {166 176}; + 165 -> {177} [style=dotted]; + 165 -> {166} [style=dashed]; 166 -> {167}; - 167 -> {168 178}; - 167 -> {179} [style=dotted]; - 167 -> {168} [style=dashed]; + 167 -> {168}; 168 -> {169}; 169 -> {170}; 170 -> {171}; @@ -610,22 +607,22 @@ digraph flowFromInplaceLambda_kt { 172 -> {173}; 173 -> {174}; 174 -> {175}; - 175 -> {176}; - 176 -> {177}; - 177 -> {179}; - 178 -> {180}; - 179 -> {167} [color=green style=dashed]; - 179 -> {180} [color=green]; - 179 -> {205} [color=red]; + 175 -> {177}; + 176 -> {178}; + 177 -> {165} [color=green style=dashed]; + 177 -> {178} [color=green]; + 177 -> {203} [color=red label="Postponed"]; + 178 -> {179}; + 179 -> {180}; 180 -> {181}; 181 -> {182}; 182 -> {183}; 183 -> {184}; - 184 -> {185}; + 184 -> {185 199}; + 184 -> {200} [style=dotted]; + 184 -> {185} [style=dashed]; 185 -> {186}; - 186 -> {187 201}; - 186 -> {202} [style=dotted]; - 186 -> {187} [style=dashed]; + 186 -> {187}; 187 -> {188}; 188 -> {189}; 189 -> {190}; @@ -637,13 +634,13 @@ digraph flowFromInplaceLambda_kt { 195 -> {196}; 196 -> {197}; 197 -> {198}; - 198 -> {199}; - 199 -> {200}; - 200 -> {202}; - 201 -> {203}; - 202 -> {186} [color=green style=dashed]; - 202 -> {203} [color=green]; - 202 -> {205} [color=red]; + 198 -> {200}; + 199 -> {201}; + 200 -> {184} [color=green style=dashed]; + 200 -> {201} [color=green]; + 200 -> {203} [color=red label="Postponed"]; + 201 -> {202}; + 202 -> {203}; 203 -> {204}; 204 -> {205}; 205 -> {206}; @@ -657,145 +654,145 @@ digraph flowFromInplaceLambda_kt { 213 -> {214}; 214 -> {215}; 215 -> {216}; - 216 -> {217}; - 217 -> {218}; - 218 -> {219}; subgraph cluster_65 { color=red - 220 [label="Enter function completedCallAtMostOnce" style="filled" fillcolor=red]; + 217 [label="Enter function completedCallAtMostOnce" style="filled" fillcolor=red]; subgraph cluster_66 { color=blue - 221 [label="Enter block"]; + 218 [label="Enter block"]; subgraph cluster_67 { color=blue - 222 [label="Function call arguments enter"]; + 219 [label="Function call arguments enter"]; subgraph cluster_68 { color=blue - 223 [label="Function call arguments enter"]; + 220 [label="Function call arguments enter"]; subgraph cluster_69 { color=blue - 224 [label="Function call arguments enter"]; + 221 [label="Function call arguments enter"]; subgraph cluster_70 { color=blue - 225 [label="Function call arguments enter"]; - 226 [label="Postponed enter to lambda"]; + 222 [label="Function call arguments enter"]; + 223 [label="Postponed enter to lambda"]; subgraph cluster_71 { color=blue - 227 [label="Enter function " style="filled" fillcolor=red]; + 224 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_72 { color=blue - 228 [label="Enter block"]; + 225 [label="Enter block"]; subgraph cluster_73 { color=blue - 229 [label="Function call arguments enter"]; - 230 [label="Access variable R|/y|"]; - 231 [label="Function call arguments exit"]; + 226 [label="Function call arguments enter"]; + 227 [label="Access variable R|/y|"]; + 228 [label="Function call arguments exit"]; } - 232 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 233 [label="Access variable R|/x|"]; - 234 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - 235 [label="Exit block"]; + 229 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 230 [label="Access variable R|/x|"]; + 231 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 232 [label="Exit block"]; } - 236 [label="Exit function " style="filled" fillcolor=red]; + 233 [label="Exit function " style="filled" fillcolor=red]; } - 237 [label="Function call arguments exit"]; + 234 [label="Function call arguments exit"]; } - 238 [label="Postponed exit from lambda"]; - 239 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; - 240 [label="Function call arguments exit"]; + 235 [label="Postponed exit from lambda"]; + 236 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; + 237 [label="Function call arguments exit"]; } - 241 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 242 [label="Access variable R|/y|"]; - 243 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 238 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 239 [label="Access variable R|/y|"]; + 240 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_74 { color=blue - 244 [label="Function call arguments enter"]; - 245 [label="Postponed enter to lambda"]; + 241 [label="Function call arguments enter"]; + 242 [label="Postponed enter to lambda"]; subgraph cluster_75 { color=blue - 246 [label="Enter function " style="filled" fillcolor=red]; + 243 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_76 { color=blue - 247 [label="Enter block"]; + 244 [label="Enter block"]; subgraph cluster_77 { color=blue - 248 [label="Function call arguments enter"]; - 249 [label="Access variable R|/x|"]; - 250 [label="Function call arguments exit"]; + 245 [label="Function call arguments enter"]; + 246 [label="Access variable R|/x|"]; + 247 [label="Function call arguments exit"]; } - 251 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 248 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_78 { color=blue - 252 [label="Function call arguments enter"]; - 253 [label="Access variable R|/y|"]; - 254 [label="Smart cast: R|/y|"]; - 255 [label="Function call arguments exit"]; + 249 [label="Function call arguments enter"]; + 250 [label="Access variable R|/y|"]; + 251 [label="Smart cast: R|/y|"]; + 252 [label="Function call arguments exit"]; } - 256 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 257 [label="Const: Int(1)"]; - 258 [label="Exit block"]; + 253 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 254 [label="Const: Int(1)"]; + 255 [label="Exit block"]; } - 259 [label="Exit function " style="filled" fillcolor=red]; + 256 [label="Exit function " style="filled" fillcolor=red]; } - 260 [label="Function call arguments exit"]; + 257 [label="Function call arguments exit"]; } - 261 [label="Postponed exit from lambda"]; - 262 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; - 263 [label="Function call arguments exit"]; + 258 [label="Postponed exit from lambda"]; + 259 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; + 260 [label="Function call arguments exit"]; } - 264 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 265 [label="Function call arguments exit"]; + 261 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 262 [label="Function call arguments exit"]; } - 266 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 263 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_79 { color=blue - 267 [label="Function call arguments enter"]; - 268 [label="Access variable R|/x|"]; - 269 [label="Function call arguments exit"]; + 264 [label="Function call arguments enter"]; + 265 [label="Access variable R|/x|"]; + 266 [label="Function call arguments exit"]; } - 270 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 267 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_80 { color=blue - 271 [label="Function call arguments enter"]; - 272 [label="Access variable R|/y|"]; - 273 [label="Smart cast: R|/y|"]; - 274 [label="Function call arguments exit"]; + 268 [label="Function call arguments enter"]; + 269 [label="Access variable R|/y|"]; + 270 [label="Smart cast: R|/y|"]; + 271 [label="Function call arguments exit"]; } - 275 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 276 [label="Exit block"]; + 272 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 273 [label="Exit block"]; } - 277 [label="Exit function completedCallAtMostOnce" style="filled" fillcolor=red]; + 274 [label="Exit function completedCallAtMostOnce" style="filled" fillcolor=red]; } + 217 -> {218}; + 218 -> {219}; + 219 -> {220}; 220 -> {221}; 221 -> {222}; 222 -> {223}; - 223 -> {224}; + 223 -> {224 234 235}; + 223 -> {224} [style=dashed]; 224 -> {225}; 225 -> {226}; - 226 -> {227 237 238}; - 226 -> {227} [style=dashed]; + 226 -> {227}; 227 -> {228}; 228 -> {229}; 229 -> {230}; 230 -> {231}; 231 -> {232}; 232 -> {233}; - 233 -> {234}; - 234 -> {235}; - 235 -> {236}; - 236 -> {238}; - 237 -> {239}; - 238 -> {239} [color=green]; - 238 -> {264} [color=red]; + 233 -> {235}; + 234 -> {236}; + 235 -> {236} [color=green]; + 235 -> {261} [color=red label="Postponed"]; + 236 -> {237}; + 237 -> {238}; + 238 -> {239}; 239 -> {240}; 240 -> {241}; 241 -> {242}; - 242 -> {243}; + 242 -> {243 257 258}; + 242 -> {243} [style=dashed]; 243 -> {244}; 244 -> {245}; - 245 -> {246 260 261}; - 245 -> {246} [style=dashed]; + 245 -> {246}; 246 -> {247}; 247 -> {248}; 248 -> {249}; @@ -806,13 +803,13 @@ digraph flowFromInplaceLambda_kt { 253 -> {254}; 254 -> {255}; 255 -> {256}; - 256 -> {257}; - 257 -> {258}; - 258 -> {259}; - 259 -> {261}; - 260 -> {262}; - 261 -> {262} [color=green]; - 261 -> {264} [color=red]; + 256 -> {258}; + 257 -> {259}; + 258 -> {259} [color=green]; + 258 -> {261} [color=red label="Postponed"]; + 259 -> {260}; + 260 -> {261}; + 261 -> {262}; 262 -> {263}; 263 -> {264}; 264 -> {265}; @@ -825,146 +822,146 @@ digraph flowFromInplaceLambda_kt { 271 -> {272}; 272 -> {273}; 273 -> {274}; - 274 -> {275}; - 275 -> {276}; - 276 -> {277}; subgraph cluster_81 { color=red - 278 [label="Enter function completedCallUnknown" style="filled" fillcolor=red]; + 275 [label="Enter function completedCallUnknown" style="filled" fillcolor=red]; subgraph cluster_82 { color=blue - 279 [label="Enter block"]; + 276 [label="Enter block"]; subgraph cluster_83 { color=blue - 280 [label="Function call arguments enter"]; + 277 [label="Function call arguments enter"]; subgraph cluster_84 { color=blue - 281 [label="Function call arguments enter"]; + 278 [label="Function call arguments enter"]; subgraph cluster_85 { color=blue - 282 [label="Function call arguments enter"]; + 279 [label="Function call arguments enter"]; subgraph cluster_86 { color=blue - 283 [label="Function call arguments enter"]; - 284 [label="Postponed enter to lambda"]; + 280 [label="Function call arguments enter"]; + 281 [label="Postponed enter to lambda"]; subgraph cluster_87 { color=blue - 285 [label="Enter function " style="filled" fillcolor=red]; + 282 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_88 { color=blue - 286 [label="Enter block"]; + 283 [label="Enter block"]; subgraph cluster_89 { color=blue - 287 [label="Function call arguments enter"]; - 288 [label="Access variable R|/y|"]; - 289 [label="Function call arguments exit"]; + 284 [label="Function call arguments enter"]; + 285 [label="Access variable R|/y|"]; + 286 [label="Function call arguments exit"]; } - 290 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 291 [label="Access variable R|/x|"]; - 292 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - 293 [label="Exit block"]; + 287 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 288 [label="Access variable R|/x|"]; + 289 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 290 [label="Exit block"]; } - 294 [label="Exit function " style="filled" fillcolor=red]; + 291 [label="Exit function " style="filled" fillcolor=red]; } - 295 [label="Function call arguments exit"]; + 292 [label="Function call arguments exit"]; } - 296 [label="Postponed exit from lambda"]; - 297 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; - 298 [label="Function call arguments exit"]; + 293 [label="Postponed exit from lambda"]; + 294 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; + 295 [label="Function call arguments exit"]; } - 299 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 300 [label="Access variable R|/y|"]; - 301 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 296 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 297 [label="Access variable R|/y|"]; + 298 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_90 { color=blue - 302 [label="Function call arguments enter"]; - 303 [label="Postponed enter to lambda"]; + 299 [label="Function call arguments enter"]; + 300 [label="Postponed enter to lambda"]; subgraph cluster_91 { color=blue - 304 [label="Enter function " style="filled" fillcolor=red]; + 301 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_92 { color=blue - 305 [label="Enter block"]; + 302 [label="Enter block"]; subgraph cluster_93 { color=blue - 306 [label="Function call arguments enter"]; - 307 [label="Access variable R|/x|"]; - 308 [label="Function call arguments exit"]; + 303 [label="Function call arguments enter"]; + 304 [label="Access variable R|/x|"]; + 305 [label="Function call arguments exit"]; } - 309 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 306 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_94 { color=blue - 310 [label="Function call arguments enter"]; - 311 [label="Access variable R|/y|"]; - 312 [label="Smart cast: R|/y|"]; - 313 [label="Function call arguments exit"]; + 307 [label="Function call arguments enter"]; + 308 [label="Access variable R|/y|"]; + 309 [label="Smart cast: R|/y|"]; + 310 [label="Function call arguments exit"]; } - 314 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 315 [label="Const: Int(1)"]; - 316 [label="Exit block"]; + 311 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 312 [label="Const: Int(1)"]; + 313 [label="Exit block"]; } - 317 [label="Exit function " style="filled" fillcolor=red]; + 314 [label="Exit function " style="filled" fillcolor=red]; } - 318 [label="Function call arguments exit"]; + 315 [label="Function call arguments exit"]; } - 319 [label="Postponed exit from lambda"]; - 320 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; - 321 [label="Function call arguments exit"]; + 316 [label="Postponed exit from lambda"]; + 317 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; + 318 [label="Function call arguments exit"]; } - 322 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 323 [label="Function call arguments exit"]; + 319 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 320 [label="Function call arguments exit"]; } - 324 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 321 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_95 { color=blue - 325 [label="Function call arguments enter"]; - 326 [label="Access variable R|/x|"]; - 327 [label="Function call arguments exit"]; + 322 [label="Function call arguments enter"]; + 323 [label="Access variable R|/x|"]; + 324 [label="Function call arguments exit"]; } - 328 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 325 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_96 { color=blue - 329 [label="Function call arguments enter"]; - 330 [label="Access variable R|/y|"]; - 331 [label="Smart cast: R|/y|"]; - 332 [label="Function call arguments exit"]; + 326 [label="Function call arguments enter"]; + 327 [label="Access variable R|/y|"]; + 328 [label="Smart cast: R|/y|"]; + 329 [label="Function call arguments exit"]; } - 333 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 334 [label="Exit block"]; + 330 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 331 [label="Exit block"]; } - 335 [label="Exit function completedCallUnknown" style="filled" fillcolor=red]; + 332 [label="Exit function completedCallUnknown" style="filled" fillcolor=red]; } + 275 -> {276}; + 276 -> {277}; + 277 -> {278}; 278 -> {279}; 279 -> {280}; 280 -> {281}; - 281 -> {282}; + 281 -> {282 292 293}; + 281 -> {282} [style=dashed]; 282 -> {283}; 283 -> {284}; - 284 -> {285 295 296}; - 284 -> {285} [style=dashed]; + 284 -> {285}; 285 -> {286}; 286 -> {287}; 287 -> {288}; 288 -> {289}; 289 -> {290}; 290 -> {291}; - 291 -> {292}; - 292 -> {293}; - 293 -> {294}; - 294 -> {296}; - 295 -> {297}; - 296 -> {284} [color=green style=dashed]; - 296 -> {297} [color=green]; - 296 -> {322} [color=red]; + 291 -> {293}; + 292 -> {294}; + 293 -> {281} [color=green style=dashed]; + 293 -> {294} [color=green]; + 293 -> {319} [color=red label="Postponed"]; + 294 -> {295}; + 295 -> {296}; + 296 -> {297}; 297 -> {298}; 298 -> {299}; 299 -> {300}; - 300 -> {301}; + 300 -> {301 315 316}; + 300 -> {301} [style=dashed]; 301 -> {302}; 302 -> {303}; - 303 -> {304 318 319}; - 303 -> {304} [style=dashed]; + 303 -> {304}; 304 -> {305}; 305 -> {306}; 306 -> {307}; @@ -975,14 +972,14 @@ digraph flowFromInplaceLambda_kt { 311 -> {312}; 312 -> {313}; 313 -> {314}; - 314 -> {315}; - 315 -> {316}; - 316 -> {317}; - 317 -> {319}; - 318 -> {320}; - 319 -> {303} [color=green style=dashed]; - 319 -> {320} [color=green]; - 319 -> {322} [color=red]; + 314 -> {316}; + 315 -> {317}; + 316 -> {300} [color=green style=dashed]; + 316 -> {317} [color=green]; + 316 -> {319} [color=red label="Postponed"]; + 317 -> {318}; + 318 -> {319}; + 319 -> {320}; 320 -> {321}; 321 -> {322}; 322 -> {323}; @@ -995,144 +992,144 @@ digraph flowFromInplaceLambda_kt { 329 -> {330}; 330 -> {331}; 331 -> {332}; - 332 -> {333}; - 333 -> {334}; - 334 -> {335}; subgraph cluster_97 { color=red - 336 [label="Enter function completedCallNoContract" style="filled" fillcolor=red]; + 333 [label="Enter function completedCallNoContract" style="filled" fillcolor=red]; subgraph cluster_98 { color=blue - 337 [label="Enter block"]; + 334 [label="Enter block"]; subgraph cluster_99 { color=blue - 338 [label="Function call arguments enter"]; + 335 [label="Function call arguments enter"]; subgraph cluster_100 { color=blue - 339 [label="Function call arguments enter"]; + 336 [label="Function call arguments enter"]; subgraph cluster_101 { color=blue - 340 [label="Function call arguments enter"]; + 337 [label="Function call arguments enter"]; subgraph cluster_102 { color=blue - 341 [label="Function call arguments enter"]; - 342 [label="Postponed enter to lambda"]; + 338 [label="Function call arguments enter"]; + 339 [label="Postponed enter to lambda"]; subgraph cluster_103 { color=blue - 343 [label="Enter function " style="filled" fillcolor=red]; + 340 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_104 { color=blue - 344 [label="Enter block"]; + 341 [label="Enter block"]; subgraph cluster_105 { color=blue - 345 [label="Function call arguments enter"]; - 346 [label="Access variable R|/y|"]; - 347 [label="Function call arguments exit"]; + 342 [label="Function call arguments enter"]; + 343 [label="Access variable R|/y|"]; + 344 [label="Function call arguments exit"]; } - 348 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 349 [label="Access variable R|/x|"]; - 350 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - 351 [label="Exit block"]; + 345 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 346 [label="Access variable R|/x|"]; + 347 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 348 [label="Exit block"]; } - 352 [label="Exit function " style="filled" fillcolor=red]; + 349 [label="Exit function " style="filled" fillcolor=red]; } - 353 [label="Function call arguments exit"]; + 350 [label="Function call arguments exit"]; } - 354 [label="Postponed exit from lambda"]; - 355 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; - 356 [label="Function call arguments exit"]; + 351 [label="Postponed exit from lambda"]; + 352 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; + 353 [label="Function call arguments exit"]; } - 357 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 358 [label="Access variable R|/y|"]; - 359 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 354 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 355 [label="Access variable R|/y|"]; + 356 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_106 { color=blue - 360 [label="Function call arguments enter"]; - 361 [label="Postponed enter to lambda"]; + 357 [label="Function call arguments enter"]; + 358 [label="Postponed enter to lambda"]; subgraph cluster_107 { color=blue - 362 [label="Enter function " style="filled" fillcolor=red]; + 359 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_108 { color=blue - 363 [label="Enter block"]; + 360 [label="Enter block"]; subgraph cluster_109 { color=blue - 364 [label="Function call arguments enter"]; - 365 [label="Access variable R|/x|"]; - 366 [label="Function call arguments exit"]; + 361 [label="Function call arguments enter"]; + 362 [label="Access variable R|/x|"]; + 363 [label="Function call arguments exit"]; } - 367 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 364 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_110 { color=blue - 368 [label="Function call arguments enter"]; - 369 [label="Access variable R|/y|"]; - 370 [label="Smart cast: R|/y|"]; - 371 [label="Function call arguments exit"]; + 365 [label="Function call arguments enter"]; + 366 [label="Access variable R|/y|"]; + 367 [label="Smart cast: R|/y|"]; + 368 [label="Function call arguments exit"]; } - 372 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 373 [label="Const: Int(1)"]; - 374 [label="Exit block"]; + 369 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 370 [label="Const: Int(1)"]; + 371 [label="Exit block"]; } - 375 [label="Exit function " style="filled" fillcolor=red]; + 372 [label="Exit function " style="filled" fillcolor=red]; } - 376 [label="Function call arguments exit"]; + 373 [label="Function call arguments exit"]; } - 377 [label="Postponed exit from lambda"]; - 378 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; - 379 [label="Function call arguments exit"]; + 374 [label="Postponed exit from lambda"]; + 375 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; + 376 [label="Function call arguments exit"]; } - 380 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 381 [label="Function call arguments exit"]; + 377 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 378 [label="Function call arguments exit"]; } - 382 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 379 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_111 { color=blue - 383 [label="Function call arguments enter"]; - 384 [label="Access variable R|/x|"]; - 385 [label="Function call arguments exit"]; + 380 [label="Function call arguments enter"]; + 381 [label="Access variable R|/x|"]; + 382 [label="Function call arguments exit"]; } - 386 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 383 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_112 { color=blue - 387 [label="Function call arguments enter"]; - 388 [label="Access variable R|/y|"]; - 389 [label="Smart cast: R|/y|"]; - 390 [label="Function call arguments exit"]; + 384 [label="Function call arguments enter"]; + 385 [label="Access variable R|/y|"]; + 386 [label="Smart cast: R|/y|"]; + 387 [label="Function call arguments exit"]; } - 391 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 392 [label="Exit block"]; + 388 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 389 [label="Exit block"]; } - 393 [label="Exit function completedCallNoContract" style="filled" fillcolor=red]; + 390 [label="Exit function completedCallNoContract" style="filled" fillcolor=red]; } + 333 -> {334}; + 334 -> {335}; + 335 -> {336}; 336 -> {337}; 337 -> {338}; 338 -> {339}; - 339 -> {340}; + 339 -> {340 350 351}; + 339 -> {340} [style=dashed]; 340 -> {341}; 341 -> {342}; - 342 -> {343 353 354}; - 342 -> {343} [style=dashed]; + 342 -> {343}; 343 -> {344}; 344 -> {345}; 345 -> {346}; 346 -> {347}; 347 -> {348}; 348 -> {349}; - 349 -> {350}; - 350 -> {351}; - 351 -> {352}; - 353 -> {355}; - 354 -> {355} [color=green]; - 354 -> {380} [color=red]; + 350 -> {352}; + 351 -> {352} [color=green]; + 351 -> {377} [color=red label="Postponed"]; + 352 -> {353}; + 353 -> {354}; + 354 -> {355}; 355 -> {356}; 356 -> {357}; 357 -> {358}; - 358 -> {359}; + 358 -> {359 373 374}; + 358 -> {359} [style=dashed]; 359 -> {360}; 360 -> {361}; - 361 -> {362 376 377}; - 361 -> {362} [style=dashed]; + 361 -> {362}; 362 -> {363}; 363 -> {364}; 364 -> {365}; @@ -1143,12 +1140,12 @@ digraph flowFromInplaceLambda_kt { 369 -> {370}; 370 -> {371}; 371 -> {372}; - 372 -> {373}; - 373 -> {374}; - 374 -> {375}; - 376 -> {378}; - 377 -> {378} [color=green]; - 377 -> {380} [color=red]; + 373 -> {375}; + 374 -> {375} [color=green]; + 374 -> {377} [color=red label="Postponed"]; + 375 -> {376}; + 376 -> {377}; + 377 -> {378}; 378 -> {379}; 379 -> {380}; 380 -> {381}; @@ -1161,140 +1158,138 @@ digraph flowFromInplaceLambda_kt { 387 -> {388}; 388 -> {389}; 389 -> {390}; - 390 -> {391}; - 391 -> {392}; - 392 -> {393}; subgraph cluster_113 { color=red - 394 [label="Enter function incompleteCallExactlyOnce" style="filled" fillcolor=red]; + 391 [label="Enter function incompleteCallExactlyOnce" style="filled" fillcolor=red]; subgraph cluster_114 { color=blue - 395 [label="Enter block"]; + 392 [label="Enter block"]; subgraph cluster_115 { color=blue - 396 [label="Function call arguments enter"]; + 393 [label="Function call arguments enter"]; subgraph cluster_116 { color=blue - 397 [label="Function call arguments enter"]; + 394 [label="Function call arguments enter"]; subgraph cluster_117 { color=blue - 398 [label="Function call arguments enter"]; + 395 [label="Function call arguments enter"]; subgraph cluster_118 { color=blue - 399 [label="Function call arguments enter"]; - 400 [label="Postponed enter to lambda"]; + 396 [label="Function call arguments enter"]; + 397 [label="Postponed enter to lambda"]; subgraph cluster_119 { color=blue - 401 [label="Enter function " style="filled" fillcolor=red]; + 398 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_120 { color=blue - 402 [label="Enter block"]; - 403 [label="Access variable R|/x|"]; - 404 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + 399 [label="Enter block"]; + 400 [label="Access variable R|/x|"]; + 401 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; subgraph cluster_121 { color=blue - 405 [label="Function call arguments enter"]; - 406 [label="Access variable R|/y|"]; - 407 [label="Function call arguments exit"]; + 402 [label="Function call arguments enter"]; + 403 [label="Access variable R|/y|"]; + 404 [label="Function call arguments exit"]; } - 408 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 405 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; subgraph cluster_122 { color=blue - 409 [label="Function call arguments enter"]; - 410 [label="Access variable R|/x|"]; - 411 [label="Smart cast: R|/x|"]; - 412 [label="Function call arguments exit"]; + 406 [label="Function call arguments enter"]; + 407 [label="Access variable R|/x|"]; + 408 [label="Smart cast: R|/x|"]; + 409 [label="Function call arguments exit"]; } - 413 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 410 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_123 { color=blue - 414 [label="Function call arguments enter"]; - 415 [label="Function call arguments exit"]; + 411 [label="Function call arguments enter"]; + 412 [label="Function call arguments exit"]; } - 416 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 417 [label="Exit block"]; + 413 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 414 [label="Exit block"]; } - 418 [label="Exit function " style="filled" fillcolor=red]; + 415 [label="Exit function " style="filled" fillcolor=red]; } - 419 [label="Function call arguments exit"]; + 416 [label="Function call arguments exit"]; } - 420 [label="Postponed exit from lambda"]; - 421 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; - 422 [label="Function call arguments exit"]; + 417 [label="Postponed exit from lambda"]; + 418 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; + 419 [label="Function call arguments exit"]; } - 423 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 420 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; subgraph cluster_124 { color=blue - 424 [label="Function call arguments enter"]; - 425 [label="Postponed enter to lambda"]; + 421 [label="Function call arguments enter"]; + 422 [label="Postponed enter to lambda"]; subgraph cluster_125 { color=blue - 426 [label="Enter function " style="filled" fillcolor=red]; + 423 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_126 { color=blue - 427 [label="Enter block"]; - 428 [label="Access variable R|/y|"]; - 429 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + 424 [label="Enter block"]; + 425 [label="Access variable R|/y|"]; + 426 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; subgraph cluster_127 { color=blue - 430 [label="Function call arguments enter"]; - 431 [label="Access variable R|/x|"]; - 432 [label="Function call arguments exit"]; + 427 [label="Function call arguments enter"]; + 428 [label="Access variable R|/x|"]; + 429 [label="Function call arguments exit"]; } - 433 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 430 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_128 { color=blue - 434 [label="Function call arguments enter"]; - 435 [label="Access variable R|/y|"]; - 436 [label="Smart cast: R|/y|"]; - 437 [label="Function call arguments exit"]; + 431 [label="Function call arguments enter"]; + 432 [label="Access variable R|/y|"]; + 433 [label="Smart cast: R|/y|"]; + 434 [label="Function call arguments exit"]; } - 438 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 439 [label="Const: Int(1)"]; - 440 [label="Exit block"]; + 435 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 436 [label="Const: Int(1)"]; + 437 [label="Exit block"]; } - 441 [label="Exit function " style="filled" fillcolor=red]; + 438 [label="Exit function " style="filled" fillcolor=red]; } - 442 [label="Function call arguments exit"]; + 439 [label="Function call arguments exit"]; } - 443 [label="Postponed exit from lambda"]; - 444 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; - 445 [label="Function call arguments exit"]; + 440 [label="Postponed exit from lambda"]; + 441 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; + 442 [label="Function call arguments exit"]; } - 446 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 447 [label="Function call arguments exit"]; + 443 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 444 [label="Function call arguments exit"]; } - 448 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 445 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; subgraph cluster_129 { color=blue - 449 [label="Function call arguments enter"]; - 450 [label="Access variable R|/x|"]; - 451 [label="Smart cast: R|/x|"]; - 452 [label="Function call arguments exit"]; + 446 [label="Function call arguments enter"]; + 447 [label="Access variable R|/x|"]; + 448 [label="Function call arguments exit"]; } - 453 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 449 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; subgraph cluster_130 { color=blue - 454 [label="Function call arguments enter"]; - 455 [label="Access variable R|/y|"]; - 456 [label="Smart cast: R|/y|"]; - 457 [label="Function call arguments exit"]; + 450 [label="Function call arguments enter"]; + 451 [label="Access variable R|/y|"]; + 452 [label="Function call arguments exit"]; } - 458 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 459 [label="Exit block"]; + 453 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 454 [label="Exit block"]; } - 460 [label="Exit function incompleteCallExactlyOnce" style="filled" fillcolor=red]; + 455 [label="Exit function incompleteCallExactlyOnce" style="filled" fillcolor=red]; } + 391 -> {392}; + 392 -> {393}; + 393 -> {394}; 394 -> {395}; 395 -> {396}; 396 -> {397}; - 397 -> {398}; + 397 -> {398 416}; + 397 -> {417} [style=dotted]; + 397 -> {398} [style=dashed]; 398 -> {399}; 399 -> {400}; - 400 -> {401 419}; - 400 -> {420} [style=dotted]; - 400 -> {401} [style=dashed]; + 400 -> {401}; 401 -> {402}; 402 -> {403}; 403 -> {404}; @@ -1309,20 +1304,20 @@ digraph flowFromInplaceLambda_kt { 412 -> {413}; 413 -> {414}; 414 -> {415}; - 415 -> {416}; - 416 -> {417}; - 417 -> {418}; - 418 -> {420}; - 419 -> {421}; - 420 -> {421} [color=green]; - 420 -> {446} [color=red]; + 415 -> {417}; + 416 -> {418}; + 417 -> {418} [color=green]; + 417 -> {443} [color=red label="Postponed"]; + 418 -> {419}; + 419 -> {420}; + 420 -> {421}; 421 -> {422}; - 422 -> {423}; + 422 -> {423 439}; + 422 -> {440} [style=dotted]; + 422 -> {423} [style=dashed]; 423 -> {424}; 424 -> {425}; - 425 -> {426 442}; - 425 -> {443} [style=dotted]; - 425 -> {426} [style=dashed]; + 425 -> {426}; 426 -> {427}; 427 -> {428}; 428 -> {429}; @@ -1335,13 +1330,13 @@ digraph flowFromInplaceLambda_kt { 435 -> {436}; 436 -> {437}; 437 -> {438}; - 438 -> {439}; - 439 -> {440}; - 440 -> {441}; - 441 -> {443}; - 442 -> {444}; - 443 -> {444} [color=green]; - 443 -> {446} [color=red]; + 438 -> {440}; + 439 -> {441}; + 440 -> {441} [color=green]; + 440 -> {443} [color=red label="Postponed"]; + 441 -> {442}; + 442 -> {443}; + 443 -> {444}; 444 -> {445}; 445 -> {446}; 446 -> {447}; @@ -1353,142 +1348,140 @@ digraph flowFromInplaceLambda_kt { 452 -> {453}; 453 -> {454}; 454 -> {455}; - 455 -> {456}; + + subgraph cluster_131 { + color=red + 456 [label="Enter function incompleteCallAtLeastOnce" style="filled" fillcolor=red]; + subgraph cluster_132 { + color=blue + 457 [label="Enter block"]; + subgraph cluster_133 { + color=blue + 458 [label="Function call arguments enter"]; + subgraph cluster_134 { + color=blue + 459 [label="Function call arguments enter"]; + subgraph cluster_135 { + color=blue + 460 [label="Function call arguments enter"]; + subgraph cluster_136 { + color=blue + 461 [label="Function call arguments enter"]; + 462 [label="Postponed enter to lambda"]; + subgraph cluster_137 { + color=blue + 463 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_138 { + color=blue + 464 [label="Enter block"]; + 465 [label="Access variable R|/x|"]; + 466 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + subgraph cluster_139 { + color=blue + 467 [label="Function call arguments enter"]; + 468 [label="Access variable R|/y|"]; + 469 [label="Function call arguments exit"]; + } + 470 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_140 { + color=blue + 471 [label="Function call arguments enter"]; + 472 [label="Access variable R|/x|"]; + 473 [label="Smart cast: R|/x|"]; + 474 [label="Function call arguments exit"]; + } + 475 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_141 { + color=blue + 476 [label="Function call arguments enter"]; + 477 [label="Function call arguments exit"]; + } + 478 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 479 [label="Exit block"]; + } + 480 [label="Exit function " style="filled" fillcolor=red]; + } + 481 [label="Function call arguments exit"]; + } + 482 [label="Postponed exit from lambda"]; + 483 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; + 484 [label="Function call arguments exit"]; + } + 485 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + subgraph cluster_142 { + color=blue + 486 [label="Function call arguments enter"]; + 487 [label="Postponed enter to lambda"]; + subgraph cluster_143 { + color=blue + 488 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_144 { + color=blue + 489 [label="Enter block"]; + 490 [label="Access variable R|/y|"]; + 491 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + subgraph cluster_145 { + color=blue + 492 [label="Function call arguments enter"]; + 493 [label="Access variable R|/x|"]; + 494 [label="Function call arguments exit"]; + } + 495 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_146 { + color=blue + 496 [label="Function call arguments enter"]; + 497 [label="Access variable R|/y|"]; + 498 [label="Smart cast: R|/y|"]; + 499 [label="Function call arguments exit"]; + } + 500 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 501 [label="Const: Int(1)"]; + 502 [label="Exit block"]; + } + 503 [label="Exit function " style="filled" fillcolor=red]; + } + 504 [label="Function call arguments exit"]; + } + 505 [label="Postponed exit from lambda"]; + 506 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; + 507 [label="Function call arguments exit"]; + } + 508 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 509 [label="Function call arguments exit"]; + } + 510 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_147 { + color=blue + 511 [label="Function call arguments enter"]; + 512 [label="Access variable R|/x|"]; + 513 [label="Function call arguments exit"]; + } + 514 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_148 { + color=blue + 515 [label="Function call arguments enter"]; + 516 [label="Access variable R|/y|"]; + 517 [label="Function call arguments exit"]; + } + 518 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 519 [label="Exit block"]; + } + 520 [label="Exit function incompleteCallAtLeastOnce" style="filled" fillcolor=red]; + } 456 -> {457}; 457 -> {458}; 458 -> {459}; 459 -> {460}; - - subgraph cluster_131 { - color=red - 461 [label="Enter function incompleteCallAtLeastOnce" style="filled" fillcolor=red]; - subgraph cluster_132 { - color=blue - 462 [label="Enter block"]; - subgraph cluster_133 { - color=blue - 463 [label="Function call arguments enter"]; - subgraph cluster_134 { - color=blue - 464 [label="Function call arguments enter"]; - subgraph cluster_135 { - color=blue - 465 [label="Function call arguments enter"]; - subgraph cluster_136 { - color=blue - 466 [label="Function call arguments enter"]; - 467 [label="Postponed enter to lambda"]; - subgraph cluster_137 { - color=blue - 468 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_138 { - color=blue - 469 [label="Enter block"]; - 470 [label="Access variable R|/x|"]; - 471 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - subgraph cluster_139 { - color=blue - 472 [label="Function call arguments enter"]; - 473 [label="Access variable R|/y|"]; - 474 [label="Function call arguments exit"]; - } - 475 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_140 { - color=blue - 476 [label="Function call arguments enter"]; - 477 [label="Access variable R|/x|"]; - 478 [label="Smart cast: R|/x|"]; - 479 [label="Function call arguments exit"]; - } - 480 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_141 { - color=blue - 481 [label="Function call arguments enter"]; - 482 [label="Function call arguments exit"]; - } - 483 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 484 [label="Exit block"]; - } - 485 [label="Exit function " style="filled" fillcolor=red]; - } - 486 [label="Function call arguments exit"]; - } - 487 [label="Postponed exit from lambda"]; - 488 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; - 489 [label="Function call arguments exit"]; - } - 490 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - subgraph cluster_142 { - color=blue - 491 [label="Function call arguments enter"]; - 492 [label="Postponed enter to lambda"]; - subgraph cluster_143 { - color=blue - 493 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_144 { - color=blue - 494 [label="Enter block"]; - 495 [label="Access variable R|/y|"]; - 496 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; - subgraph cluster_145 { - color=blue - 497 [label="Function call arguments enter"]; - 498 [label="Access variable R|/x|"]; - 499 [label="Function call arguments exit"]; - } - 500 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_146 { - color=blue - 501 [label="Function call arguments enter"]; - 502 [label="Access variable R|/y|"]; - 503 [label="Smart cast: R|/y|"]; - 504 [label="Function call arguments exit"]; - } - 505 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 506 [label="Const: Int(1)"]; - 507 [label="Exit block"]; - } - 508 [label="Exit function " style="filled" fillcolor=red]; - } - 509 [label="Function call arguments exit"]; - } - 510 [label="Postponed exit from lambda"]; - 511 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; - 512 [label="Function call arguments exit"]; - } - 513 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 514 [label="Function call arguments exit"]; - } - 515 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_147 { - color=blue - 516 [label="Function call arguments enter"]; - 517 [label="Access variable R|/x|"]; - 518 [label="Smart cast: R|/x|"]; - 519 [label="Function call arguments exit"]; - } - 520 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_148 { - color=blue - 521 [label="Function call arguments enter"]; - 522 [label="Access variable R|/y|"]; - 523 [label="Smart cast: R|/y|"]; - 524 [label="Function call arguments exit"]; - } - 525 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 526 [label="Exit block"]; - } - 527 [label="Exit function incompleteCallAtLeastOnce" style="filled" fillcolor=red]; - } + 460 -> {461}; 461 -> {462}; - 462 -> {463}; + 462 -> {463 481}; + 462 -> {482} [style=dotted]; + 462 -> {463} [style=dashed]; 463 -> {464}; 464 -> {465}; 465 -> {466}; 466 -> {467}; - 467 -> {468 486}; - 467 -> {487} [style=dotted]; - 467 -> {468} [style=dashed]; + 467 -> {468}; 468 -> {469}; 469 -> {470}; 470 -> {471}; @@ -1501,23 +1494,23 @@ digraph flowFromInplaceLambda_kt { 477 -> {478}; 478 -> {479}; 479 -> {480}; - 480 -> {481}; - 481 -> {482}; - 482 -> {483}; + 480 -> {482}; + 481 -> {483}; + 482 -> {462} [color=green style=dashed]; + 482 -> {483} [color=green]; + 482 -> {508} [color=red label="Postponed"]; 483 -> {484}; 484 -> {485}; - 485 -> {487}; - 486 -> {488}; - 487 -> {467} [color=green style=dashed]; - 487 -> {488} [color=green]; - 487 -> {513} [color=red]; + 485 -> {486}; + 486 -> {487}; + 487 -> {488 504}; + 487 -> {505} [style=dotted]; + 487 -> {488} [style=dashed]; 488 -> {489}; 489 -> {490}; 490 -> {491}; 491 -> {492}; - 492 -> {493 509}; - 492 -> {510} [style=dotted]; - 492 -> {493} [style=dashed]; + 492 -> {493}; 493 -> {494}; 494 -> {495}; 495 -> {496}; @@ -1528,16 +1521,16 @@ digraph flowFromInplaceLambda_kt { 500 -> {501}; 501 -> {502}; 502 -> {503}; - 503 -> {504}; - 504 -> {505}; - 505 -> {506}; + 503 -> {505}; + 504 -> {506}; + 505 -> {487} [color=green style=dashed]; + 505 -> {506} [color=green]; + 505 -> {508} [color=red label="Postponed"]; 506 -> {507}; 507 -> {508}; - 508 -> {510}; - 509 -> {511}; - 510 -> {492} [color=green style=dashed]; - 510 -> {511} [color=green]; - 510 -> {513} [color=red]; + 508 -> {509}; + 509 -> {510}; + 510 -> {511}; 511 -> {512}; 512 -> {513}; 513 -> {514}; @@ -1547,141 +1540,141 @@ digraph flowFromInplaceLambda_kt { 517 -> {518}; 518 -> {519}; 519 -> {520}; - 520 -> {521}; + + subgraph cluster_149 { + color=red + 521 [label="Enter function incompleteCallAtMostOnce" style="filled" fillcolor=red]; + subgraph cluster_150 { + color=blue + 522 [label="Enter block"]; + subgraph cluster_151 { + color=blue + 523 [label="Function call arguments enter"]; + subgraph cluster_152 { + color=blue + 524 [label="Function call arguments enter"]; + subgraph cluster_153 { + color=blue + 525 [label="Function call arguments enter"]; + subgraph cluster_154 { + color=blue + 526 [label="Function call arguments enter"]; + 527 [label="Postponed enter to lambda"]; + subgraph cluster_155 { + color=blue + 528 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_156 { + color=blue + 529 [label="Enter block"]; + 530 [label="Access variable R|/x|"]; + 531 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + subgraph cluster_157 { + color=blue + 532 [label="Function call arguments enter"]; + 533 [label="Access variable R|/y|"]; + 534 [label="Function call arguments exit"]; + } + 535 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_158 { + color=blue + 536 [label="Function call arguments enter"]; + 537 [label="Access variable R|/x|"]; + 538 [label="Smart cast: R|/x|"]; + 539 [label="Function call arguments exit"]; + } + 540 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_159 { + color=blue + 541 [label="Function call arguments enter"]; + 542 [label="Function call arguments exit"]; + } + 543 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 544 [label="Exit block"]; + } + 545 [label="Exit function " style="filled" fillcolor=red]; + } + 546 [label="Function call arguments exit"]; + } + 547 [label="Postponed exit from lambda"]; + 548 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; + 549 [label="Function call arguments exit"]; + } + 550 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + subgraph cluster_160 { + color=blue + 551 [label="Function call arguments enter"]; + 552 [label="Postponed enter to lambda"]; + subgraph cluster_161 { + color=blue + 553 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_162 { + color=blue + 554 [label="Enter block"]; + 555 [label="Access variable R|/y|"]; + 556 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + subgraph cluster_163 { + color=blue + 557 [label="Function call arguments enter"]; + 558 [label="Access variable R|/x|"]; + 559 [label="Function call arguments exit"]; + } + 560 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_164 { + color=blue + 561 [label="Function call arguments enter"]; + 562 [label="Access variable R|/y|"]; + 563 [label="Smart cast: R|/y|"]; + 564 [label="Function call arguments exit"]; + } + 565 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 566 [label="Const: Int(1)"]; + 567 [label="Exit block"]; + } + 568 [label="Exit function " style="filled" fillcolor=red]; + } + 569 [label="Function call arguments exit"]; + } + 570 [label="Postponed exit from lambda"]; + 571 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; + 572 [label="Function call arguments exit"]; + } + 573 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 574 [label="Function call arguments exit"]; + } + 575 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_165 { + color=blue + 576 [label="Function call arguments enter"]; + 577 [label="Access variable R|/x|"]; + 578 [label="Function call arguments exit"]; + } + 579 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_166 { + color=blue + 580 [label="Function call arguments enter"]; + 581 [label="Access variable R|/y|"]; + 582 [label="Function call arguments exit"]; + } + 583 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 584 [label="Exit block"]; + } + 585 [label="Exit function incompleteCallAtMostOnce" style="filled" fillcolor=red]; + } 521 -> {522}; 522 -> {523}; 523 -> {524}; 524 -> {525}; 525 -> {526}; 526 -> {527}; - - subgraph cluster_149 { - color=red - 528 [label="Enter function incompleteCallAtMostOnce" style="filled" fillcolor=red]; - subgraph cluster_150 { - color=blue - 529 [label="Enter block"]; - subgraph cluster_151 { - color=blue - 530 [label="Function call arguments enter"]; - subgraph cluster_152 { - color=blue - 531 [label="Function call arguments enter"]; - subgraph cluster_153 { - color=blue - 532 [label="Function call arguments enter"]; - subgraph cluster_154 { - color=blue - 533 [label="Function call arguments enter"]; - 534 [label="Postponed enter to lambda"]; - subgraph cluster_155 { - color=blue - 535 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_156 { - color=blue - 536 [label="Enter block"]; - 537 [label="Access variable R|/x|"]; - 538 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - subgraph cluster_157 { - color=blue - 539 [label="Function call arguments enter"]; - 540 [label="Access variable R|/y|"]; - 541 [label="Function call arguments exit"]; - } - 542 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_158 { - color=blue - 543 [label="Function call arguments enter"]; - 544 [label="Access variable R|/x|"]; - 545 [label="Smart cast: R|/x|"]; - 546 [label="Function call arguments exit"]; - } - 547 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_159 { - color=blue - 548 [label="Function call arguments enter"]; - 549 [label="Function call arguments exit"]; - } - 550 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 551 [label="Exit block"]; - } - 552 [label="Exit function " style="filled" fillcolor=red]; - } - 553 [label="Function call arguments exit"]; - } - 554 [label="Postponed exit from lambda"]; - 555 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; - 556 [label="Function call arguments exit"]; - } - 557 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - subgraph cluster_160 { - color=blue - 558 [label="Function call arguments enter"]; - 559 [label="Postponed enter to lambda"]; - subgraph cluster_161 { - color=blue - 560 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_162 { - color=blue - 561 [label="Enter block"]; - 562 [label="Access variable R|/y|"]; - 563 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; - subgraph cluster_163 { - color=blue - 564 [label="Function call arguments enter"]; - 565 [label="Access variable R|/x|"]; - 566 [label="Function call arguments exit"]; - } - 567 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_164 { - color=blue - 568 [label="Function call arguments enter"]; - 569 [label="Access variable R|/y|"]; - 570 [label="Smart cast: R|/y|"]; - 571 [label="Function call arguments exit"]; - } - 572 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 573 [label="Const: Int(1)"]; - 574 [label="Exit block"]; - } - 575 [label="Exit function " style="filled" fillcolor=red]; - } - 576 [label="Function call arguments exit"]; - } - 577 [label="Postponed exit from lambda"]; - 578 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; - 579 [label="Function call arguments exit"]; - } - 580 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 581 [label="Function call arguments exit"]; - } - 582 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_165 { - color=blue - 583 [label="Function call arguments enter"]; - 584 [label="Access variable R|/x|"]; - 585 [label="Function call arguments exit"]; - } - 586 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_166 { - color=blue - 587 [label="Function call arguments enter"]; - 588 [label="Access variable R|/y|"]; - 589 [label="Function call arguments exit"]; - } - 590 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 591 [label="Exit block"]; - } - 592 [label="Exit function incompleteCallAtMostOnce" style="filled" fillcolor=red]; - } + 527 -> {528 546 547}; + 527 -> {528} [style=dashed]; 528 -> {529}; 529 -> {530}; 530 -> {531}; 531 -> {532}; 532 -> {533}; 533 -> {534}; - 534 -> {535 553 554}; - 534 -> {535} [style=dashed]; + 534 -> {535}; 535 -> {536}; 536 -> {537}; 537 -> {538}; @@ -1692,23 +1685,23 @@ digraph flowFromInplaceLambda_kt { 542 -> {543}; 543 -> {544}; 544 -> {545}; - 545 -> {546}; - 546 -> {547}; - 547 -> {548}; + 545 -> {547}; + 546 -> {548}; + 547 -> {548} [color=green]; + 547 -> {573} [color=red label="Postponed"]; 548 -> {549}; 549 -> {550}; 550 -> {551}; 551 -> {552}; - 552 -> {554}; - 553 -> {555}; - 554 -> {555} [color=green]; - 554 -> {580} [color=red]; + 552 -> {553 569 570}; + 552 -> {553} [style=dashed]; + 553 -> {554}; + 554 -> {555}; 555 -> {556}; 556 -> {557}; 557 -> {558}; 558 -> {559}; - 559 -> {560 576 577}; - 559 -> {560} [style=dashed]; + 559 -> {560}; 560 -> {561}; 561 -> {562}; 562 -> {563}; @@ -1717,17 +1710,17 @@ digraph flowFromInplaceLambda_kt { 565 -> {566}; 566 -> {567}; 567 -> {568}; - 568 -> {569}; - 569 -> {570}; - 570 -> {571}; + 568 -> {570}; + 569 -> {571}; + 570 -> {571} [color=green]; + 570 -> {573} [color=red label="Postponed"]; 571 -> {572}; 572 -> {573}; 573 -> {574}; 574 -> {575}; - 575 -> {577}; - 576 -> {578}; - 577 -> {578} [color=green]; - 577 -> {580} [color=red]; + 575 -> {576}; + 576 -> {577}; + 577 -> {578}; 578 -> {579}; 579 -> {580}; 580 -> {581}; @@ -1735,141 +1728,141 @@ digraph flowFromInplaceLambda_kt { 582 -> {583}; 583 -> {584}; 584 -> {585}; - 585 -> {586}; + + subgraph cluster_167 { + color=red + 586 [label="Enter function incompleteCallUnknown" style="filled" fillcolor=red]; + subgraph cluster_168 { + color=blue + 587 [label="Enter block"]; + subgraph cluster_169 { + color=blue + 588 [label="Function call arguments enter"]; + subgraph cluster_170 { + color=blue + 589 [label="Function call arguments enter"]; + subgraph cluster_171 { + color=blue + 590 [label="Function call arguments enter"]; + subgraph cluster_172 { + color=blue + 591 [label="Function call arguments enter"]; + 592 [label="Postponed enter to lambda"]; + subgraph cluster_173 { + color=blue + 593 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_174 { + color=blue + 594 [label="Enter block"]; + 595 [label="Access variable R|/x|"]; + 596 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + subgraph cluster_175 { + color=blue + 597 [label="Function call arguments enter"]; + 598 [label="Access variable R|/y|"]; + 599 [label="Function call arguments exit"]; + } + 600 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_176 { + color=blue + 601 [label="Function call arguments enter"]; + 602 [label="Access variable R|/x|"]; + 603 [label="Smart cast: R|/x|"]; + 604 [label="Function call arguments exit"]; + } + 605 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_177 { + color=blue + 606 [label="Function call arguments enter"]; + 607 [label="Function call arguments exit"]; + } + 608 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 609 [label="Exit block"]; + } + 610 [label="Exit function " style="filled" fillcolor=red]; + } + 611 [label="Function call arguments exit"]; + } + 612 [label="Postponed exit from lambda"]; + 613 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; + 614 [label="Function call arguments exit"]; + } + 615 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + subgraph cluster_178 { + color=blue + 616 [label="Function call arguments enter"]; + 617 [label="Postponed enter to lambda"]; + subgraph cluster_179 { + color=blue + 618 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_180 { + color=blue + 619 [label="Enter block"]; + 620 [label="Access variable R|/y|"]; + 621 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + subgraph cluster_181 { + color=blue + 622 [label="Function call arguments enter"]; + 623 [label="Access variable R|/x|"]; + 624 [label="Function call arguments exit"]; + } + 625 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_182 { + color=blue + 626 [label="Function call arguments enter"]; + 627 [label="Access variable R|/y|"]; + 628 [label="Smart cast: R|/y|"]; + 629 [label="Function call arguments exit"]; + } + 630 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 631 [label="Const: Int(1)"]; + 632 [label="Exit block"]; + } + 633 [label="Exit function " style="filled" fillcolor=red]; + } + 634 [label="Function call arguments exit"]; + } + 635 [label="Postponed exit from lambda"]; + 636 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; + 637 [label="Function call arguments exit"]; + } + 638 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 639 [label="Function call arguments exit"]; + } + 640 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_183 { + color=blue + 641 [label="Function call arguments enter"]; + 642 [label="Access variable R|/x|"]; + 643 [label="Function call arguments exit"]; + } + 644 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_184 { + color=blue + 645 [label="Function call arguments enter"]; + 646 [label="Access variable R|/y|"]; + 647 [label="Function call arguments exit"]; + } + 648 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 649 [label="Exit block"]; + } + 650 [label="Exit function incompleteCallUnknown" style="filled" fillcolor=red]; + } 586 -> {587}; 587 -> {588}; 588 -> {589}; 589 -> {590}; 590 -> {591}; 591 -> {592}; - - subgraph cluster_167 { - color=red - 593 [label="Enter function incompleteCallUnknown" style="filled" fillcolor=red]; - subgraph cluster_168 { - color=blue - 594 [label="Enter block"]; - subgraph cluster_169 { - color=blue - 595 [label="Function call arguments enter"]; - subgraph cluster_170 { - color=blue - 596 [label="Function call arguments enter"]; - subgraph cluster_171 { - color=blue - 597 [label="Function call arguments enter"]; - subgraph cluster_172 { - color=blue - 598 [label="Function call arguments enter"]; - 599 [label="Postponed enter to lambda"]; - subgraph cluster_173 { - color=blue - 600 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_174 { - color=blue - 601 [label="Enter block"]; - 602 [label="Access variable R|/x|"]; - 603 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - subgraph cluster_175 { - color=blue - 604 [label="Function call arguments enter"]; - 605 [label="Access variable R|/y|"]; - 606 [label="Function call arguments exit"]; - } - 607 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_176 { - color=blue - 608 [label="Function call arguments enter"]; - 609 [label="Access variable R|/x|"]; - 610 [label="Smart cast: R|/x|"]; - 611 [label="Function call arguments exit"]; - } - 612 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_177 { - color=blue - 613 [label="Function call arguments enter"]; - 614 [label="Function call arguments exit"]; - } - 615 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 616 [label="Exit block"]; - } - 617 [label="Exit function " style="filled" fillcolor=red]; - } - 618 [label="Function call arguments exit"]; - } - 619 [label="Postponed exit from lambda"]; - 620 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; - 621 [label="Function call arguments exit"]; - } - 622 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - subgraph cluster_178 { - color=blue - 623 [label="Function call arguments enter"]; - 624 [label="Postponed enter to lambda"]; - subgraph cluster_179 { - color=blue - 625 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_180 { - color=blue - 626 [label="Enter block"]; - 627 [label="Access variable R|/y|"]; - 628 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; - subgraph cluster_181 { - color=blue - 629 [label="Function call arguments enter"]; - 630 [label="Access variable R|/x|"]; - 631 [label="Function call arguments exit"]; - } - 632 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_182 { - color=blue - 633 [label="Function call arguments enter"]; - 634 [label="Access variable R|/y|"]; - 635 [label="Smart cast: R|/y|"]; - 636 [label="Function call arguments exit"]; - } - 637 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 638 [label="Const: Int(1)"]; - 639 [label="Exit block"]; - } - 640 [label="Exit function " style="filled" fillcolor=red]; - } - 641 [label="Function call arguments exit"]; - } - 642 [label="Postponed exit from lambda"]; - 643 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; - 644 [label="Function call arguments exit"]; - } - 645 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 646 [label="Function call arguments exit"]; - } - 647 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_183 { - color=blue - 648 [label="Function call arguments enter"]; - 649 [label="Access variable R|/x|"]; - 650 [label="Function call arguments exit"]; - } - 651 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_184 { - color=blue - 652 [label="Function call arguments enter"]; - 653 [label="Access variable R|/y|"]; - 654 [label="Function call arguments exit"]; - } - 655 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 656 [label="Exit block"]; - } - 657 [label="Exit function incompleteCallUnknown" style="filled" fillcolor=red]; - } + 592 -> {593 611 612}; + 592 -> {593} [style=dashed]; 593 -> {594}; 594 -> {595}; 595 -> {596}; 596 -> {597}; 597 -> {598}; 598 -> {599}; - 599 -> {600 618 619}; - 599 -> {600} [style=dashed]; + 599 -> {600}; 600 -> {601}; 601 -> {602}; 602 -> {603}; @@ -1880,24 +1873,24 @@ digraph flowFromInplaceLambda_kt { 607 -> {608}; 608 -> {609}; 609 -> {610}; - 610 -> {611}; - 611 -> {612}; - 612 -> {613}; + 610 -> {612}; + 611 -> {613}; + 612 -> {592} [color=green style=dashed]; + 612 -> {613} [color=green]; + 612 -> {638} [color=red label="Postponed"]; 613 -> {614}; 614 -> {615}; 615 -> {616}; 616 -> {617}; - 617 -> {619}; - 618 -> {620}; - 619 -> {599} [color=green style=dashed]; - 619 -> {620} [color=green]; - 619 -> {645} [color=red]; + 617 -> {618 634 635}; + 617 -> {618} [style=dashed]; + 618 -> {619}; + 619 -> {620}; 620 -> {621}; 621 -> {622}; 622 -> {623}; 623 -> {624}; - 624 -> {625 641 642}; - 624 -> {625} [style=dashed]; + 624 -> {625}; 625 -> {626}; 626 -> {627}; 627 -> {628}; @@ -1906,18 +1899,18 @@ digraph flowFromInplaceLambda_kt { 630 -> {631}; 631 -> {632}; 632 -> {633}; - 633 -> {634}; - 634 -> {635}; - 635 -> {636}; + 633 -> {635}; + 634 -> {636}; + 635 -> {617} [color=green style=dashed]; + 635 -> {636} [color=green]; + 635 -> {638} [color=red label="Postponed"]; 636 -> {637}; 637 -> {638}; 638 -> {639}; 639 -> {640}; - 640 -> {642}; - 641 -> {643}; - 642 -> {624} [color=green style=dashed]; - 642 -> {643} [color=green]; - 642 -> {645} [color=red]; + 640 -> {641}; + 641 -> {642}; + 642 -> {643}; 643 -> {644}; 644 -> {645}; 645 -> {646}; @@ -1925,141 +1918,141 @@ digraph flowFromInplaceLambda_kt { 647 -> {648}; 648 -> {649}; 649 -> {650}; - 650 -> {651}; + + subgraph cluster_185 { + color=red + 651 [label="Enter function incompleteCallNoContract" style="filled" fillcolor=red]; + subgraph cluster_186 { + color=blue + 652 [label="Enter block"]; + subgraph cluster_187 { + color=blue + 653 [label="Function call arguments enter"]; + subgraph cluster_188 { + color=blue + 654 [label="Function call arguments enter"]; + subgraph cluster_189 { + color=blue + 655 [label="Function call arguments enter"]; + subgraph cluster_190 { + color=blue + 656 [label="Function call arguments enter"]; + 657 [label="Postponed enter to lambda"]; + subgraph cluster_191 { + color=blue + 658 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_192 { + color=blue + 659 [label="Enter block"]; + 660 [label="Access variable R|/x|"]; + 661 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; + subgraph cluster_193 { + color=blue + 662 [label="Function call arguments enter"]; + 663 [label="Access variable R|/y|"]; + 664 [label="Function call arguments exit"]; + } + 665 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_194 { + color=blue + 666 [label="Function call arguments enter"]; + 667 [label="Access variable R|/x|"]; + 668 [label="Smart cast: R|/x|"]; + 669 [label="Function call arguments exit"]; + } + 670 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_195 { + color=blue + 671 [label="Function call arguments enter"]; + 672 [label="Function call arguments exit"]; + } + 673 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 674 [label="Exit block"]; + } + 675 [label="Exit function " style="filled" fillcolor=red]; + } + 676 [label="Function call arguments exit"]; + } + 677 [label="Postponed exit from lambda"]; + 678 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; + 679 [label="Function call arguments exit"]; + } + 680 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + subgraph cluster_196 { + color=blue + 681 [label="Function call arguments enter"]; + 682 [label="Postponed enter to lambda"]; + subgraph cluster_197 { + color=blue + 683 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_198 { + color=blue + 684 [label="Enter block"]; + 685 [label="Access variable R|/y|"]; + 686 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; + subgraph cluster_199 { + color=blue + 687 [label="Function call arguments enter"]; + 688 [label="Access variable R|/x|"]; + 689 [label="Function call arguments exit"]; + } + 690 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_200 { + color=blue + 691 [label="Function call arguments enter"]; + 692 [label="Access variable R|/y|"]; + 693 [label="Smart cast: R|/y|"]; + 694 [label="Function call arguments exit"]; + } + 695 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 696 [label="Const: Int(1)"]; + 697 [label="Exit block"]; + } + 698 [label="Exit function " style="filled" fillcolor=red]; + } + 699 [label="Function call arguments exit"]; + } + 700 [label="Postponed exit from lambda"]; + 701 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; + 702 [label="Function call arguments exit"]; + } + 703 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 704 [label="Function call arguments exit"]; + } + 705 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + subgraph cluster_201 { + color=blue + 706 [label="Function call arguments enter"]; + 707 [label="Access variable R|/x|"]; + 708 [label="Function call arguments exit"]; + } + 709 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + subgraph cluster_202 { + color=blue + 710 [label="Function call arguments enter"]; + 711 [label="Access variable R|/y|"]; + 712 [label="Function call arguments exit"]; + } + 713 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; + 714 [label="Exit block"]; + } + 715 [label="Exit function incompleteCallNoContract" style="filled" fillcolor=red]; + } 651 -> {652}; 652 -> {653}; 653 -> {654}; 654 -> {655}; 655 -> {656}; 656 -> {657}; - - subgraph cluster_185 { - color=red - 658 [label="Enter function incompleteCallNoContract" style="filled" fillcolor=red]; - subgraph cluster_186 { - color=blue - 659 [label="Enter block"]; - subgraph cluster_187 { - color=blue - 660 [label="Function call arguments enter"]; - subgraph cluster_188 { - color=blue - 661 [label="Function call arguments enter"]; - subgraph cluster_189 { - color=blue - 662 [label="Function call arguments enter"]; - subgraph cluster_190 { - color=blue - 663 [label="Function call arguments enter"]; - 664 [label="Postponed enter to lambda"]; - subgraph cluster_191 { - color=blue - 665 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_192 { - color=blue - 666 [label="Enter block"]; - 667 [label="Access variable R|/x|"]; - 668 [label="Type operator: (R|/x| as R|kotlin/Int|)"]; - subgraph cluster_193 { - color=blue - 669 [label="Function call arguments enter"]; - 670 [label="Access variable R|/y|"]; - 671 [label="Function call arguments exit"]; - } - 672 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_194 { - color=blue - 673 [label="Function call arguments enter"]; - 674 [label="Access variable R|/x|"]; - 675 [label="Smart cast: R|/x|"]; - 676 [label="Function call arguments exit"]; - } - 677 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_195 { - color=blue - 678 [label="Function call arguments enter"]; - 679 [label="Function call arguments exit"]; - } - 680 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 681 [label="Exit block"]; - } - 682 [label="Exit function " style="filled" fillcolor=red]; - } - 683 [label="Function call arguments exit"]; - } - 684 [label="Postponed exit from lambda"]; - 685 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; - 686 [label="Function call arguments exit"]; - } - 687 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - subgraph cluster_196 { - color=blue - 688 [label="Function call arguments enter"]; - 689 [label="Postponed enter to lambda"]; - subgraph cluster_197 { - color=blue - 690 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_198 { - color=blue - 691 [label="Enter block"]; - 692 [label="Access variable R|/y|"]; - 693 [label="Type operator: (R|/y| as R|kotlin/Int|)"]; - subgraph cluster_199 { - color=blue - 694 [label="Function call arguments enter"]; - 695 [label="Access variable R|/x|"]; - 696 [label="Function call arguments exit"]; - } - 697 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_200 { - color=blue - 698 [label="Function call arguments enter"]; - 699 [label="Access variable R|/y|"]; - 700 [label="Smart cast: R|/y|"]; - 701 [label="Function call arguments exit"]; - } - 702 [label="Function call: R|/y|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 703 [label="Const: Int(1)"]; - 704 [label="Exit block"]; - } - 705 [label="Exit function " style="filled" fillcolor=red]; - } - 706 [label="Function call arguments exit"]; - } - 707 [label="Postponed exit from lambda"]; - 708 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; - 709 [label="Function call arguments exit"]; - } - 710 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 711 [label="Function call arguments exit"]; - } - 712 [label="Function call: R|/select|(...).R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - subgraph cluster_201 { - color=blue - 713 [label="Function call arguments enter"]; - 714 [label="Access variable R|/x|"]; - 715 [label="Function call arguments exit"]; - } - 716 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - subgraph cluster_202 { - color=blue - 717 [label="Function call arguments enter"]; - 718 [label="Access variable R|/y|"]; - 719 [label="Function call arguments exit"]; - } - 720 [label="Function call: R|/y|.#()" style="filled" fillcolor=yellow]; - 721 [label="Exit block"]; - } - 722 [label="Exit function incompleteCallNoContract" style="filled" fillcolor=red]; - } + 657 -> {658 676 677}; + 657 -> {658} [style=dashed]; 658 -> {659}; 659 -> {660}; 660 -> {661}; 661 -> {662}; 662 -> {663}; 663 -> {664}; - 664 -> {665 683 684}; - 664 -> {665} [style=dashed]; + 664 -> {665}; 665 -> {666}; 666 -> {667}; 667 -> {668}; @@ -2070,22 +2063,22 @@ digraph flowFromInplaceLambda_kt { 672 -> {673}; 673 -> {674}; 674 -> {675}; - 675 -> {676}; - 676 -> {677}; - 677 -> {678}; + 676 -> {678}; + 677 -> {678} [color=green]; + 677 -> {703} [color=red label="Postponed"]; 678 -> {679}; 679 -> {680}; 680 -> {681}; 681 -> {682}; - 683 -> {685}; - 684 -> {685} [color=green]; - 684 -> {710} [color=red]; + 682 -> {683 699 700}; + 682 -> {683} [style=dashed]; + 683 -> {684}; + 684 -> {685}; 685 -> {686}; 686 -> {687}; 687 -> {688}; 688 -> {689}; - 689 -> {690 706 707}; - 689 -> {690} [style=dashed]; + 689 -> {690}; 690 -> {691}; 691 -> {692}; 692 -> {693}; @@ -2094,16 +2087,16 @@ digraph flowFromInplaceLambda_kt { 695 -> {696}; 696 -> {697}; 697 -> {698}; - 698 -> {699}; - 699 -> {700}; - 700 -> {701}; + 699 -> {701}; + 700 -> {701} [color=green]; + 700 -> {703} [color=red label="Postponed"]; 701 -> {702}; 702 -> {703}; 703 -> {704}; 704 -> {705}; - 706 -> {708}; - 707 -> {708} [color=green]; - 707 -> {710} [color=red]; + 705 -> {706}; + 706 -> {707}; + 707 -> {708}; 708 -> {709}; 709 -> {710}; 710 -> {711}; @@ -2111,229 +2104,222 @@ digraph flowFromInplaceLambda_kt { 712 -> {713}; 713 -> {714}; 714 -> {715}; - 715 -> {716}; + + subgraph cluster_203 { + color=red + 716 [label="Enter function expectedType" style="filled" fillcolor=red]; + subgraph cluster_204 { + color=blue + 717 [label="Enter block"]; + subgraph cluster_205 { + color=blue + 718 [label="Function call arguments enter"]; + subgraph cluster_206 { + color=blue + 719 [label="Function call arguments enter"]; + 720 [label="Postponed enter to lambda"]; + subgraph cluster_207 { + color=blue + 721 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_208 { + color=blue + 722 [label="Enter block"]; + subgraph cluster_209 { + color=blue + 723 [label="Function call arguments enter"]; + 724 [label="Function call arguments exit"]; + } + 725 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 726 [label="Exit block"]; + } + 727 [label="Exit function " style="filled" fillcolor=red]; + } + 728 [label="Function call arguments exit"]; + } + 729 [label="Postponed exit from lambda"]; + 730 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + subgraph cluster_210 { + color=blue + 731 [label="Function call arguments enter"]; + 732 [label="Postponed enter to lambda"]; + subgraph cluster_211 { + color=blue + 733 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_212 { + color=blue + 734 [label="Enter block"]; + subgraph cluster_213 { + color=blue + 735 [label="Function call arguments enter"]; + 736 [label="Function call arguments exit"]; + } + 737 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 738 [label="Exit block"]; + } + 739 [label="Exit function " style="filled" fillcolor=red]; + } + 740 [label="Function call arguments exit"]; + } + 741 [label="Postponed exit from lambda"]; + 742 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 743 [label="Function call arguments exit"]; + } + 744 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; + 745 [label="Variable declaration: lval x: R|kotlin/Int|"]; + subgraph cluster_214 { + color=blue + 746 [label="Function call arguments enter"]; + 747 [label="Access variable R|/x|"]; + 748 [label="Function call arguments exit"]; + } + 749 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 750 [label="Exit block"]; + } + 751 [label="Exit function expectedType" style="filled" fillcolor=red]; + } 716 -> {717}; 717 -> {718}; 718 -> {719}; 719 -> {720}; - 720 -> {721}; + 720 -> {721 728}; + 720 -> {729} [style=dotted]; + 720 -> {721} [style=dashed]; 721 -> {722}; - - subgraph cluster_203 { - color=red - 723 [label="Enter function expectedType" style="filled" fillcolor=red]; - subgraph cluster_204 { - color=blue - 724 [label="Enter block"]; - subgraph cluster_205 { - color=blue - 725 [label="Function call arguments enter"]; - subgraph cluster_206 { - color=blue - 726 [label="Function call arguments enter"]; - 727 [label="Postponed enter to lambda"]; - subgraph cluster_207 { - color=blue - 728 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_208 { - color=blue - 729 [label="Enter block"]; - subgraph cluster_209 { - color=blue - 730 [label="Function call arguments enter"]; - 731 [label="Function call arguments exit"]; - } - 732 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 733 [label="Exit block"]; - } - 734 [label="Exit function " style="filled" fillcolor=red]; - } - 735 [label="Function call arguments exit"]; - } - 736 [label="Postponed exit from lambda"]; - 737 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - subgraph cluster_210 { - color=blue - 738 [label="Function call arguments enter"]; - 739 [label="Postponed enter to lambda"]; - subgraph cluster_211 { - color=blue - 740 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_212 { - color=blue - 741 [label="Enter block"]; - subgraph cluster_213 { - color=blue - 742 [label="Function call arguments enter"]; - 743 [label="Function call arguments exit"]; - } - 744 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 745 [label="Exit block"]; - } - 746 [label="Exit function " style="filled" fillcolor=red]; - } - 747 [label="Function call arguments exit"]; - } - 748 [label="Postponed exit from lambda"]; - 749 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 750 [label="Function call arguments exit"]; - } - 751 [label="Function call: R|/select|(...)" style="filled" fillcolor=yellow]; - 752 [label="Variable declaration: lval x: R|kotlin/Int|"]; - subgraph cluster_214 { - color=blue - 753 [label="Function call arguments enter"]; - 754 [label="Access variable R|/x|"]; - 755 [label="Function call arguments exit"]; - } - 756 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 757 [label="Exit block"]; - } - 758 [label="Exit function expectedType" style="filled" fillcolor=red]; - } + 722 -> {723}; 723 -> {724}; 724 -> {725}; 725 -> {726}; 726 -> {727}; - 727 -> {728 735}; - 727 -> {736} [style=dotted]; - 727 -> {728} [style=dashed]; - 728 -> {729}; - 729 -> {730}; + 727 -> {729}; + 728 -> {730}; + 729 -> {730} [color=green]; + 729 -> {744} [color=red label="Postponed"]; 730 -> {731}; 731 -> {732}; - 732 -> {733}; + 732 -> {733 740}; + 732 -> {741} [style=dotted]; + 732 -> {733} [style=dashed]; 733 -> {734}; - 734 -> {736}; - 735 -> {737}; - 736 -> {737} [color=green]; - 736 -> {751} [color=red]; + 734 -> {735}; + 735 -> {736}; + 736 -> {737}; 737 -> {738}; 738 -> {739}; - 739 -> {740 747}; - 739 -> {748} [style=dotted]; - 739 -> {740} [style=dashed]; - 740 -> {741}; - 741 -> {742}; + 739 -> {741}; + 740 -> {742}; + 741 -> {742} [color=green]; + 741 -> {744} [color=red label="Postponed"]; 742 -> {743}; 743 -> {744}; 744 -> {745}; 745 -> {746}; - 746 -> {748}; - 747 -> {749}; - 748 -> {749} [color=green]; - 748 -> {751} [color=red]; + 746 -> {747}; + 747 -> {748}; + 748 -> {749}; 749 -> {750}; 750 -> {751}; - 751 -> {752}; + + subgraph cluster_215 { + color=red + 752 [label="Enter function expectedTypeNested" style="filled" fillcolor=red]; + subgraph cluster_216 { + color=blue + 753 [label="Enter block"]; + subgraph cluster_217 { + color=blue + 754 [label="Function call arguments enter"]; + subgraph cluster_218 { + color=blue + 755 [label="Function call arguments enter"]; + 756 [label="Postponed enter to lambda"]; + subgraph cluster_219 { + color=blue + 757 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_220 { + color=blue + 758 [label="Enter block"]; + subgraph cluster_221 { + color=blue + 759 [label="Function call arguments enter"]; + 760 [label="Postponed enter to lambda"]; + subgraph cluster_222 { + color=blue + 761 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_223 { + color=blue + 762 [label="Enter block"]; + subgraph cluster_224 { + color=blue + 763 [label="Function call arguments enter"]; + 764 [label="Function call arguments exit"]; + } + 765 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; + 766 [label="Exit block"]; + } + 767 [label="Exit function " style="filled" fillcolor=red]; + } + 768 [label="Function call arguments exit"]; + } + 769 [label="Postponed exit from lambda"]; + 770 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 771 [label="Exit block"]; + } + 772 [label="Exit function " style="filled" fillcolor=red]; + } + 773 [label="Function call arguments exit"]; + } + 774 [label="Postponed exit from lambda"]; + 775 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; + 776 [label="Function call arguments exit"]; + } + 777 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 778 [label="Variable declaration: lval x: R|kotlin/Int|"]; + subgraph cluster_225 { + color=blue + 779 [label="Function call arguments enter"]; + 780 [label="Access variable R|/x|"]; + 781 [label="Function call arguments exit"]; + } + 782 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; + 783 [label="Exit block"]; + } + 784 [label="Exit function expectedTypeNested" style="filled" fillcolor=red]; + } 752 -> {753}; 753 -> {754}; 754 -> {755}; 755 -> {756}; - 756 -> {757}; + 756 -> {757 773 774}; + 756 -> {757} [style=dashed]; 757 -> {758}; - - subgraph cluster_215 { - color=red - 759 [label="Enter function expectedTypeNested" style="filled" fillcolor=red]; - subgraph cluster_216 { - color=blue - 760 [label="Enter block"]; - subgraph cluster_217 { - color=blue - 761 [label="Function call arguments enter"]; - subgraph cluster_218 { - color=blue - 762 [label="Function call arguments enter"]; - 763 [label="Postponed enter to lambda"]; - subgraph cluster_219 { - color=blue - 764 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_220 { - color=blue - 765 [label="Enter block"]; - subgraph cluster_221 { - color=blue - 766 [label="Function call arguments enter"]; - 767 [label="Postponed enter to lambda"]; - subgraph cluster_222 { - color=blue - 768 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_223 { - color=blue - 769 [label="Enter block"]; - subgraph cluster_224 { - color=blue - 770 [label="Function call arguments enter"]; - 771 [label="Function call arguments exit"]; - } - 772 [label="Function call: R|/materialize|()" style="filled" fillcolor=yellow]; - 773 [label="Exit block"]; - } - 774 [label="Exit function " style="filled" fillcolor=red]; - } - 775 [label="Function call arguments exit"]; - } - 776 [label="Postponed exit from lambda"]; - 777 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 778 [label="Exit block"]; - } - 779 [label="Exit function " style="filled" fillcolor=red]; - } - 780 [label="Function call arguments exit"]; - } - 781 [label="Postponed exit from lambda"]; - 782 [label="Function call: R|/noContract|(...)" style="filled" fillcolor=yellow]; - 783 [label="Function call arguments exit"]; - } - 784 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 785 [label="Variable declaration: lval x: R|kotlin/Int|"]; - subgraph cluster_225 { - color=blue - 786 [label="Function call arguments enter"]; - 787 [label="Access variable R|/x|"]; - 788 [label="Function call arguments exit"]; - } - 789 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 790 [label="Exit block"]; - } - 791 [label="Exit function expectedTypeNested" style="filled" fillcolor=red]; - } + 758 -> {759}; 759 -> {760}; - 760 -> {761}; + 760 -> {761 768}; + 760 -> {769} [style=dotted]; + 760 -> {761} [style=dashed]; 761 -> {762}; 762 -> {763}; - 763 -> {764 780 781}; - 763 -> {764} [style=dashed]; + 763 -> {764}; 764 -> {765}; 765 -> {766}; 766 -> {767}; - 767 -> {768 775}; - 767 -> {776} [style=dotted]; - 767 -> {768} [style=dashed]; - 768 -> {769}; - 769 -> {770}; + 767 -> {769}; + 768 -> {770}; + 769 -> {770} [color=green]; + 769 -> {777} [color=red label="Postponed"]; 770 -> {771}; 771 -> {772}; - 772 -> {773}; - 773 -> {774}; - 774 -> {776}; - 775 -> {777}; - 776 -> {777} [color=green]; - 776 -> {784} [color=red]; + 773 -> {775}; + 774 -> {775} [color=green]; + 774 -> {777} [color=red label="Postponed"]; + 775 -> {776}; + 776 -> {777}; 777 -> {778}; 778 -> {779}; - 780 -> {782}; - 781 -> {782} [color=green]; - 781 -> {784} [color=red]; + 779 -> {780}; + 780 -> {781}; + 781 -> {782}; 782 -> {783}; 783 -> {784}; - 784 -> {785}; - 785 -> {786}; - 786 -> {787}; - 787 -> {788}; - 788 -> {789}; - 789 -> {790}; - 790 -> {791}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.fir.txt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.fir.txt index 11206efe03f..4c51fda9113 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.fir.txt @@ -76,7 +76,7 @@ FILE: flowFromInplaceLambda.kt ^ (R|/x| as R|kotlin/Int|) } ) - R|/x|.R|kotlin/Int.inc|() + R|/x|.#() } public final fun completedCallExactlyOnce(x: R|kotlin/Any?|, y: R|kotlin/Any?|): R|kotlin/Unit| { R|/select|(vararg(R|/id|(R|/exactlyOnce|( = exactlyOnce@fun (): R|kotlin/Int| { @@ -89,7 +89,7 @@ FILE: flowFromInplaceLambda.kt ^ Int(1) } ))).R|kotlin/Int.inc|() - R|/x|.R|kotlin/Int.inc|() + R|/x|.#() R|/y|.R|kotlin/Int.inc|() } public final fun completedCallAtLeastOnce(x: R|kotlin/Any?|, y: R|kotlin/Any?|): R|kotlin/Unit| { @@ -103,7 +103,7 @@ FILE: flowFromInplaceLambda.kt ^ Int(1) } ))).R|kotlin/Int.inc|() - R|/x|.R|kotlin/Int.inc|() + R|/x|.#() R|/y|.R|kotlin/Int.inc|() } public final fun completedCallAtMostOnce(x: R|kotlin/Any?|, y: R|kotlin/Any?|): R|kotlin/Unit| { @@ -162,8 +162,8 @@ FILE: flowFromInplaceLambda.kt ^ Int(1) } ))).R|kotlin/Int.inc|() - R|/x|.R|kotlin/Int.inc|() - R|/y|.R|kotlin/Int.inc|() + R|/x|.#() + R|/y|.#() } public final fun incompleteCallAtLeastOnce(x: R|kotlin/Any|, y: R|kotlin/Any|): R|kotlin/Unit| { R|/select|(vararg(R|/id|(R|/atLeastOnce|( = atLeastOnce@fun (): R|kotlin/Int| { @@ -179,8 +179,8 @@ FILE: flowFromInplaceLambda.kt ^ Int(1) } ))).R|kotlin/Int.inc|() - R|/x|.R|kotlin/Int.inc|() - R|/y|.R|kotlin/Int.inc|() + R|/x|.#() + R|/y|.#() } public final fun incompleteCallAtMostOnce(x: R|kotlin/Any|, y: R|kotlin/Any|): R|kotlin/Unit| { R|/select|(vararg(R|/id|(R|/atMostOnce|( = atMostOnce@fun (): R|kotlin/Int| { diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.kt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.kt index 4e17a8cb0d7..1fa6d7fc632 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.kt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda.kt @@ -31,7 +31,7 @@ fun materialize(): K = null!! fun basic(x: Any?) { exactlyOnce { x as Int } - x.inc() // OK + x.inc() // Bad: KT-37838 -> OK } fun completedCallExactlyOnce(x: Any?, y: Any?) { @@ -41,7 +41,7 @@ fun completedCallExactlyOnce(x: Any?, y: Any?) { y as Int, exactlyOnce { x.inc(); y.inc(); 1 } ).inc() // OK - x.inc() // OK + x.inc() // Bad: KT-37838 -> OK y.inc() // OK } @@ -51,7 +51,7 @@ fun completedCallAtLeastOnce(x: Any?, y: Any?) { y as Int, atLeastOnce { x.inc(); y.inc(); 1 } ).inc() // OK - x.inc() // OK + x.inc() // Bad: KT-37838 -> OK y.inc() // OK } @@ -91,8 +91,8 @@ fun incompleteCallExactlyOnce(x: Any, y: Any) { id(exactlyOnce { x as Int; y.inc(); x.inc(); materialize() }), exactlyOnce { y as Int; x.inc(); y.inc(); 1 } ).inc() // OK - x.inc() // OK - y.inc() // OK + x.inc() // Bad: KT-37838 -> OK + y.inc() // Bad: KT-37838 -> OK } fun incompleteCallAtLeastOnce(x: Any, y: Any) { @@ -100,8 +100,8 @@ fun incompleteCallAtLeastOnce(x: Any, y: Any) { id(atLeastOnce { x as Int; y.inc(); x.inc(); materialize() }), atLeastOnce { y as Int; x.inc(); y.inc(); 1 } ).inc() // OK - x.inc() // OK - y.inc() // OK + x.inc() // Bad: KT-37838 -> OK + y.inc() // Bad: KT-37838 -> OK } fun incompleteCallAtMostOnce(x: Any, y: Any) { diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.dot index f4008011c9f..3c3a055207c 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.dot @@ -154,11 +154,10 @@ digraph flowFromInplaceLambda2_kt { } 61 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; 62 [label="Access variable R|/x|"]; - 63 [label="Smart cast: R|/x|"]; - 64 [label="Access variable R|kotlin/String.length|"]; - 65 [label="Exit block"]; + 63 [label="Access variable R|kotlin/String.length#|"]; + 64 [label="Exit block"]; } - 66 [label="Exit function test1" style="filled" fillcolor=red]; + 65 [label="Exit function test1" style="filled" fillcolor=red]; } 27 -> {28}; 28 -> {29}; @@ -179,7 +178,7 @@ digraph flowFromInplaceLambda2_kt { 41 -> {43}; 42 -> {44}; 43 -> {44} [color=green]; - 43 -> {61} [color=red]; + 43 -> {61} [color=red label="Postponed"]; 44 -> {45}; 45 -> {46}; 46 -> {47}; @@ -197,102 +196,101 @@ digraph flowFromInplaceLambda2_kt { 56 -> {58}; 57 -> {59}; 58 -> {59} [color=green]; - 58 -> {61} [color=red]; + 58 -> {61} [color=red label="Postponed"]; 59 -> {60}; 60 -> {61}; 61 -> {62}; 62 -> {63}; 63 -> {64}; 64 -> {65}; - 65 -> {66}; subgraph cluster_20 { color=red - 67 [label="Enter function test2" style="filled" fillcolor=red]; + 66 [label="Enter function test2" style="filled" fillcolor=red]; subgraph cluster_21 { color=blue - 68 [label="Enter block"]; + 67 [label="Enter block"]; subgraph cluster_22 { color=blue - 69 [label="Function call arguments enter"]; + 68 [label="Function call arguments enter"]; subgraph cluster_23 { color=blue - 70 [label="Function call arguments enter"]; + 69 [label="Function call arguments enter"]; subgraph cluster_24 { color=blue - 71 [label="Function call arguments enter"]; - 72 [label="Postponed enter to lambda"]; + 70 [label="Function call arguments enter"]; + 71 [label="Postponed enter to lambda"]; subgraph cluster_25 { color=blue - 73 [label="Enter function " style="filled" fillcolor=red]; + 72 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_26 { color=blue - 74 [label="Enter block"]; - 75 [label="Access variable R|/x|"]; - 76 [label="Type operator: (R|/x| as R|kotlin/String|)"]; + 73 [label="Enter block"]; + 74 [label="Access variable R|/x|"]; + 75 [label="Type operator: (R|/x| as R|kotlin/String|)"]; subgraph cluster_27 { color=blue - 77 [label="Function call arguments enter"]; - 78 [label="Function call arguments exit"]; + 76 [label="Function call arguments enter"]; + 77 [label="Function call arguments exit"]; } - 79 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 80 [label="Exit block"]; + 78 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 79 [label="Exit block"]; } - 81 [label="Exit function " style="filled" fillcolor=red]; + 80 [label="Exit function " style="filled" fillcolor=red]; } - 82 [label="Function call arguments exit"]; + 81 [label="Function call arguments exit"]; } - 83 [label="Postponed exit from lambda"]; - 84 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 85 [label="Function call arguments exit"]; + 82 [label="Postponed exit from lambda"]; + 83 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 84 [label="Function call arguments exit"]; } - 86 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 85 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; subgraph cluster_28 { color=blue - 87 [label="Function call arguments enter"]; - 88 [label="Const: Int(1)"]; - 89 [label="Function call arguments exit"]; + 86 [label="Function call arguments enter"]; + 87 [label="Const: Int(1)"]; + 88 [label="Function call arguments exit"]; } - 90 [label="Function call: R|/someCompletedCall|(...)" style="filled" fillcolor=yellow]; + 89 [label="Function call: R|/someCompletedCall|(...)" style="filled" fillcolor=yellow]; subgraph cluster_29 { color=blue - 91 [label="Function call arguments enter"]; - 92 [label="Postponed enter to lambda"]; + 90 [label="Function call arguments enter"]; + 91 [label="Postponed enter to lambda"]; subgraph cluster_30 { color=blue - 93 [label="Enter function " style="filled" fillcolor=red]; + 92 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_31 { color=blue - 94 [label="Enter block"]; - 95 [label="Access variable R|/x|"]; - 96 [label="Access variable R|kotlin/String.length#|"]; - 97 [label="Const: Int(123)"]; - 98 [label="Exit block"]; + 93 [label="Enter block"]; + 94 [label="Access variable R|/x|"]; + 95 [label="Access variable R|kotlin/String.length#|"]; + 96 [label="Const: Int(123)"]; + 97 [label="Exit block"]; } - 99 [label="Exit function " style="filled" fillcolor=red]; + 98 [label="Exit function " style="filled" fillcolor=red]; } - 100 [label="Function call arguments exit"]; + 99 [label="Function call arguments exit"]; } - 101 [label="Postponed exit from lambda"]; - 102 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 103 [label="Function call arguments exit"]; + 100 [label="Postponed exit from lambda"]; + 101 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 102 [label="Function call arguments exit"]; } - 104 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 105 [label="Access variable R|/x|"]; - 106 [label="Smart cast: R|/x|"]; - 107 [label="Access variable R|kotlin/String.length|"]; - 108 [label="Exit block"]; + 103 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 104 [label="Access variable R|/x|"]; + 105 [label="Access variable R|kotlin/String.length#|"]; + 106 [label="Exit block"]; } - 109 [label="Exit function test2" style="filled" fillcolor=red]; + 107 [label="Exit function test2" style="filled" fillcolor=red]; } + 66 -> {67}; 67 -> {68}; 68 -> {69}; 69 -> {70}; 70 -> {71}; - 71 -> {72}; - 72 -> {73 82}; - 72 -> {83} [style=dotted]; - 72 -> {73} [style=dashed]; + 71 -> {72 81}; + 71 -> {82} [style=dotted]; + 71 -> {72} [style=dashed]; + 72 -> {73}; 73 -> {74}; 74 -> {75}; 75 -> {76}; @@ -300,11 +298,11 @@ digraph flowFromInplaceLambda2_kt { 77 -> {78}; 78 -> {79}; 79 -> {80}; - 80 -> {81}; + 80 -> {82}; 81 -> {83}; - 82 -> {84}; - 83 -> {84} [color=green]; - 83 -> {104} [color=red]; + 82 -> {83} [color=green]; + 82 -> {103} [color=red label="Postponed"]; + 83 -> {84}; 84 -> {85}; 85 -> {86}; 86 -> {87}; @@ -312,911 +310,905 @@ digraph flowFromInplaceLambda2_kt { 88 -> {89}; 89 -> {90}; 90 -> {91}; - 91 -> {92}; - 92 -> {93 100}; - 92 -> {101} [style=dotted]; - 92 -> {93} [style=dashed]; + 91 -> {92 99}; + 91 -> {100} [style=dotted]; + 91 -> {92} [style=dashed]; + 92 -> {93}; 93 -> {94}; 94 -> {95}; 95 -> {96}; 96 -> {97}; 97 -> {98}; - 98 -> {99}; + 98 -> {100}; 99 -> {101}; - 100 -> {102}; - 101 -> {102} [color=green]; - 101 -> {104} [color=red]; + 100 -> {101} [color=green]; + 100 -> {103} [color=red label="Postponed"]; + 101 -> {102}; 102 -> {103}; 103 -> {104}; 104 -> {105}; 105 -> {106}; 106 -> {107}; - 107 -> {108}; - 108 -> {109}; subgraph cluster_32 { color=red - 110 [label="Enter function test3" style="filled" fillcolor=red]; + 108 [label="Enter function test3" style="filled" fillcolor=red]; subgraph cluster_33 { color=blue - 111 [label="Enter block"]; + 109 [label="Enter block"]; subgraph cluster_34 { color=blue - 112 [label="Function call arguments enter"]; + 110 [label="Function call arguments enter"]; subgraph cluster_35 { color=blue - 113 [label="Function call arguments enter"]; + 111 [label="Function call arguments enter"]; subgraph cluster_36 { color=blue - 114 [label="Function call arguments enter"]; - 115 [label="Postponed enter to lambda"]; + 112 [label="Function call arguments enter"]; + 113 [label="Postponed enter to lambda"]; subgraph cluster_37 { color=blue - 116 [label="Enter function " style="filled" fillcolor=red]; + 114 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_38 { color=blue - 117 [label="Enter block"]; - 118 [label="Access variable R|/x|"]; - 119 [label="Type operator: (R|/x| as R|kotlin/String|)"]; + 115 [label="Enter block"]; + 116 [label="Access variable R|/x|"]; + 117 [label="Type operator: (R|/x| as R|kotlin/String|)"]; subgraph cluster_39 { color=blue - 120 [label="Function call arguments enter"]; - 121 [label="Function call arguments exit"]; + 118 [label="Function call arguments enter"]; + 119 [label="Function call arguments exit"]; } - 122 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 123 [label="Exit block"]; + 120 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 121 [label="Exit block"]; } - 124 [label="Exit function " style="filled" fillcolor=red]; + 122 [label="Exit function " style="filled" fillcolor=red]; } - 125 [label="Function call arguments exit"]; + 123 [label="Function call arguments exit"]; } - 126 [label="Postponed exit from lambda"]; - 127 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 128 [label="Function call arguments exit"]; + 124 [label="Postponed exit from lambda"]; + 125 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 126 [label="Function call arguments exit"]; } - 129 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 127 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; subgraph cluster_40 { color=blue - 130 [label="Enter when"]; + 128 [label="Enter when"]; subgraph cluster_41 { color=blue - 131 [label="Enter when branch condition "]; - 132 [label="Const: Boolean(true)"]; - 133 [label="Exit when branch condition"]; + 129 [label="Enter when branch condition "]; + 130 [label="Const: Boolean(true)"]; + 131 [label="Exit when branch condition"]; } subgraph cluster_42 { color=blue - 134 [label="Enter when branch condition else"]; - 135 [label="Exit when branch condition"]; + 132 [label="Enter when branch condition else"]; + 133 [label="Exit when branch condition"]; } - 136 [label="Enter when branch result"]; + 134 [label="Enter when branch result"]; subgraph cluster_43 { color=blue - 137 [label="Enter block"]; - 138 [label="Const: Int(2)"]; - 139 [label="Exit block"]; + 135 [label="Enter block"]; + 136 [label="Const: Int(2)"]; + 137 [label="Exit block"]; } - 140 [label="Exit when branch result"]; - 141 [label="Enter when branch result"]; + 138 [label="Exit when branch result"]; + 139 [label="Enter when branch result"]; subgraph cluster_44 { color=blue - 142 [label="Enter block"]; - 143 [label="Const: Int(1)"]; - 144 [label="Exit block"]; + 140 [label="Enter block"]; + 141 [label="Const: Int(1)"]; + 142 [label="Exit block"]; } - 145 [label="Exit when branch result"]; - 146 [label="Exit when"]; + 143 [label="Exit when branch result"]; + 144 [label="Exit when"]; } subgraph cluster_45 { color=blue - 147 [label="Function call arguments enter"]; - 148 [label="Postponed enter to lambda"]; + 145 [label="Function call arguments enter"]; + 146 [label="Postponed enter to lambda"]; subgraph cluster_46 { color=blue - 149 [label="Enter function " style="filled" fillcolor=red]; + 147 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_47 { color=blue - 150 [label="Enter block"]; - 151 [label="Access variable R|/x|"]; - 152 [label="Access variable R|kotlin/String.length#|"]; - 153 [label="Const: Int(123)"]; - 154 [label="Exit block"]; + 148 [label="Enter block"]; + 149 [label="Access variable R|/x|"]; + 150 [label="Access variable R|kotlin/String.length#|"]; + 151 [label="Const: Int(123)"]; + 152 [label="Exit block"]; } - 155 [label="Exit function " style="filled" fillcolor=red]; + 153 [label="Exit function " style="filled" fillcolor=red]; } - 156 [label="Function call arguments exit"]; + 154 [label="Function call arguments exit"]; } - 157 [label="Postponed exit from lambda"]; - 158 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 159 [label="Function call arguments exit"]; + 155 [label="Postponed exit from lambda"]; + 156 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 157 [label="Function call arguments exit"]; } - 160 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 161 [label="Access variable R|/x|"]; - 162 [label="Smart cast: R|/x|"]; - 163 [label="Access variable R|kotlin/String.length|"]; - 164 [label="Exit block"]; + 158 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 159 [label="Access variable R|/x|"]; + 160 [label="Access variable R|kotlin/String.length#|"]; + 161 [label="Exit block"]; } - 165 [label="Exit function test3" style="filled" fillcolor=red]; + 162 [label="Exit function test3" style="filled" fillcolor=red]; } + 108 -> {109}; + 109 -> {110}; 110 -> {111}; 111 -> {112}; 112 -> {113}; - 113 -> {114}; + 113 -> {114 123}; + 113 -> {124} [style=dotted]; + 113 -> {114} [style=dashed]; 114 -> {115}; - 115 -> {116 125}; - 115 -> {126} [style=dotted]; - 115 -> {116} [style=dashed]; + 115 -> {116}; 116 -> {117}; 117 -> {118}; 118 -> {119}; 119 -> {120}; 120 -> {121}; 121 -> {122}; - 122 -> {123}; - 123 -> {124}; - 124 -> {126}; - 125 -> {127}; - 126 -> {127} [color=green]; - 126 -> {160} [color=red]; + 122 -> {124}; + 123 -> {125}; + 124 -> {125} [color=green]; + 124 -> {158} [color=red label="Postponed"]; + 125 -> {126}; + 126 -> {127}; 127 -> {128}; 128 -> {129}; 129 -> {130}; 130 -> {131}; - 131 -> {132}; + 131 -> {132 139}; 132 -> {133}; - 133 -> {134 141}; + 133 -> {134}; 134 -> {135}; 135 -> {136}; 136 -> {137}; 137 -> {138}; - 138 -> {139}; + 138 -> {144}; 139 -> {140}; - 140 -> {146}; + 140 -> {141}; 141 -> {142}; 142 -> {143}; 143 -> {144}; 144 -> {145}; 145 -> {146}; - 146 -> {147}; + 146 -> {147 154}; + 146 -> {155} [style=dotted]; + 146 -> {147} [style=dashed]; 147 -> {148}; - 148 -> {149 156}; - 148 -> {157} [style=dotted]; - 148 -> {149} [style=dashed]; + 148 -> {149}; 149 -> {150}; 150 -> {151}; 151 -> {152}; 152 -> {153}; - 153 -> {154}; - 154 -> {155}; - 155 -> {157}; - 156 -> {158}; - 157 -> {158} [color=green]; - 157 -> {160} [color=red]; + 153 -> {155}; + 154 -> {156}; + 155 -> {156} [color=green]; + 155 -> {158} [color=red label="Postponed"]; + 156 -> {157}; + 157 -> {158}; 158 -> {159}; 159 -> {160}; 160 -> {161}; 161 -> {162}; - 162 -> {163}; - 163 -> {164}; - 164 -> {165}; subgraph cluster_48 { color=red - 166 [label="Enter function test4" style="filled" fillcolor=red]; + 163 [label="Enter function test4" style="filled" fillcolor=red]; subgraph cluster_49 { color=blue - 167 [label="Enter block"]; - 168 [label="Access variable R|/x|"]; - 169 [label="Variable declaration: lvar p: R|kotlin/String?|"]; + 164 [label="Enter block"]; + 165 [label="Access variable R|/x|"]; + 166 [label="Variable declaration: lvar p: R|kotlin/String?|"]; subgraph cluster_50 { color=blue - 170 [label="Enter when"]; + 167 [label="Enter when"]; subgraph cluster_51 { color=blue - 171 [label="Enter when branch condition "]; - 172 [label="Access variable R|/p|"]; - 173 [label="Const: Null(null)"]; - 174 [label="Equality operator !="]; - 175 [label="Exit when branch condition"]; + 168 [label="Enter when branch condition "]; + 169 [label="Access variable R|/p|"]; + 170 [label="Const: Null(null)"]; + 171 [label="Equality operator !="]; + 172 [label="Exit when branch condition"]; } - 176 [label="Synthetic else branch"]; - 177 [label="Enter when branch result"]; + 173 [label="Synthetic else branch"]; + 174 [label="Enter when branch result"]; subgraph cluster_52 { color=blue - 178 [label="Enter block"]; + 175 [label="Enter block"]; subgraph cluster_53 { color=blue - 179 [label="Function call arguments enter"]; + 176 [label="Function call arguments enter"]; subgraph cluster_54 { color=blue - 180 [label="Function call arguments enter"]; + 177 [label="Function call arguments enter"]; subgraph cluster_55 { color=blue - 181 [label="Enter when"]; + 178 [label="Enter when"]; subgraph cluster_56 { color=blue - 182 [label="Enter when branch condition "]; - 183 [label="Const: Boolean(true)"]; - 184 [label="Exit when branch condition"]; + 179 [label="Enter when branch condition "]; + 180 [label="Const: Boolean(true)"]; + 181 [label="Exit when branch condition"]; } subgraph cluster_57 { color=blue - 185 [label="Enter when branch condition else"]; - 186 [label="Exit when branch condition"]; + 182 [label="Enter when branch condition else"]; + 183 [label="Exit when branch condition"]; } - 187 [label="Enter when branch result"]; + 184 [label="Enter when branch result"]; subgraph cluster_58 { color=blue - 188 [label="Enter block"]; + 185 [label="Enter block"]; subgraph cluster_59 { color=blue - 189 [label="Function call arguments enter"]; - 190 [label="Postponed enter to lambda"]; + 186 [label="Function call arguments enter"]; + 187 [label="Postponed enter to lambda"]; subgraph cluster_60 { color=blue - 191 [label="Enter function " style="filled" fillcolor=red]; + 188 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_61 { color=blue - 192 [label="Enter block"]; + 189 [label="Enter block"]; subgraph cluster_62 { color=blue - 193 [label="Function call arguments enter"]; - 194 [label="Function call arguments exit"]; + 190 [label="Function call arguments enter"]; + 191 [label="Function call arguments exit"]; } - 195 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 196 [label="Exit block"]; + 192 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 193 [label="Exit block"]; } - 197 [label="Exit function " style="filled" fillcolor=red]; + 194 [label="Exit function " style="filled" fillcolor=red]; } - 198 [label="Function call arguments exit"]; + 195 [label="Function call arguments exit"]; } - 199 [label="Postponed exit from lambda"]; - 200 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 201 [label="Exit block"]; + 196 [label="Postponed exit from lambda"]; + 197 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 198 [label="Exit block"]; } - 202 [label="Exit when branch result"]; - 203 [label="Enter when branch result"]; + 199 [label="Exit when branch result"]; + 200 [label="Enter when branch result"]; subgraph cluster_63 { color=blue - 204 [label="Enter block"]; + 201 [label="Enter block"]; subgraph cluster_64 { color=blue - 205 [label="Function call arguments enter"]; - 206 [label="Postponed enter to lambda"]; + 202 [label="Function call arguments enter"]; + 203 [label="Postponed enter to lambda"]; subgraph cluster_65 { color=blue - 207 [label="Enter function " style="filled" fillcolor=red]; + 204 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_66 { color=blue - 208 [label="Enter block"]; - 209 [label="Const: Null(null)"]; - 210 [label="Assignment: R|/p|"]; + 205 [label="Enter block"]; + 206 [label="Const: Null(null)"]; + 207 [label="Assignment: R|/p|"]; subgraph cluster_67 { color=blue - 211 [label="Function call arguments enter"]; - 212 [label="Function call arguments exit"]; + 208 [label="Function call arguments enter"]; + 209 [label="Function call arguments exit"]; } - 213 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 214 [label="Exit block"]; + 210 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 211 [label="Exit block"]; } - 215 [label="Exit function " style="filled" fillcolor=red]; + 212 [label="Exit function " style="filled" fillcolor=red]; } - 216 [label="Function call arguments exit"]; + 213 [label="Function call arguments exit"]; } - 217 [label="Postponed exit from lambda"]; - 218 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 219 [label="Exit block"]; + 214 [label="Postponed exit from lambda"]; + 215 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 216 [label="Exit block"]; } - 220 [label="Exit when branch result"]; - 221 [label="Exit when"]; + 217 [label="Exit when branch result"]; + 218 [label="Exit when"]; } - 222 [label="Function call arguments exit"]; + 219 [label="Function call arguments exit"]; } - 223 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 224 [label="Const: Int(1)"]; + 220 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 221 [label="Const: Int(1)"]; subgraph cluster_68 { color=blue - 225 [label="Function call arguments enter"]; - 226 [label="Postponed enter to lambda"]; + 222 [label="Function call arguments enter"]; + 223 [label="Postponed enter to lambda"]; subgraph cluster_69 { color=blue - 227 [label="Enter function " style="filled" fillcolor=red]; + 224 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_70 { color=blue - 228 [label="Enter block"]; - 229 [label="Access variable R|/p|"]; - 230 [label="Smart cast: R|/p|"]; - 231 [label="Access variable R|kotlin/String.length#|"]; - 232 [label="Const: Int(123)"]; - 233 [label="Exit block"]; + 225 [label="Enter block"]; + 226 [label="Access variable R|/p|"]; + 227 [label="Smart cast: R|/p|"]; + 228 [label="Access variable R|kotlin/String.length#|"]; + 229 [label="Const: Int(123)"]; + 230 [label="Exit block"]; } - 234 [label="Exit function " style="filled" fillcolor=red]; + 231 [label="Exit function " style="filled" fillcolor=red]; } - 235 [label="Function call arguments exit"]; + 232 [label="Function call arguments exit"]; } - 236 [label="Postponed exit from lambda"]; - 237 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 238 [label="Function call arguments exit"]; + 233 [label="Postponed exit from lambda"]; + 234 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 235 [label="Function call arguments exit"]; } - 239 [label="Merge postponed lambda exits"]; - 240 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 241 [label="Access variable R|/p|"]; - 242 [label="Access variable R|kotlin/String.length#|"]; - 243 [label="Exit block"]; + 236 [label="Merge postponed lambda exits"]; + 237 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 238 [label="Access variable R|/p|"]; + 239 [label="Access variable R|kotlin/String.length#|"]; + 240 [label="Exit block"]; } - 244 [label="Exit when branch result"]; - 245 [label="Exit when"]; + 241 [label="Exit when branch result"]; + 242 [label="Exit when"]; } - 246 [label="Exit block"]; + 243 [label="Exit block"]; } - 247 [label="Exit function test4" style="filled" fillcolor=red]; + 244 [label="Exit function test4" style="filled" fillcolor=red]; } + 163 -> {164}; + 164 -> {165}; + 165 -> {166}; 166 -> {167}; 167 -> {168}; 168 -> {169}; 169 -> {170}; 170 -> {171}; 171 -> {172}; - 172 -> {173}; - 173 -> {174}; + 172 -> {173 174}; + 173 -> {242}; 174 -> {175}; - 175 -> {176 177}; - 176 -> {245}; + 175 -> {176}; + 176 -> {177}; 177 -> {178}; 178 -> {179}; 179 -> {180}; 180 -> {181}; - 181 -> {182}; + 181 -> {182 200}; 182 -> {183}; 183 -> {184}; - 184 -> {185 203}; + 184 -> {185}; 185 -> {186}; 186 -> {187}; - 187 -> {188}; + 187 -> {188 195}; + 187 -> {196} [style=dotted]; + 187 -> {188} [style=dashed]; 188 -> {189}; 189 -> {190}; - 190 -> {191 198}; - 190 -> {199} [style=dotted]; - 190 -> {191} [style=dashed]; + 190 -> {191}; 191 -> {192}; 192 -> {193}; 193 -> {194}; - 194 -> {195}; - 195 -> {196}; - 196 -> {197}; - 197 -> {199}; - 198 -> {200}; - 199 -> {200} [color=green]; - 199 -> {239} [color=red]; + 194 -> {196}; + 195 -> {197}; + 196 -> {197} [color=green]; + 196 -> {236} [color=red]; + 197 -> {198}; + 198 -> {199}; + 199 -> {218}; 200 -> {201}; 201 -> {202}; - 202 -> {221}; - 203 -> {204}; + 202 -> {203}; + 203 -> {204 213}; + 203 -> {214} [style=dotted]; + 203 -> {204} [style=dashed]; 204 -> {205}; 205 -> {206}; - 206 -> {207 216}; - 206 -> {217} [style=dotted]; - 206 -> {207} [style=dashed]; + 206 -> {207}; 207 -> {208}; 208 -> {209}; 209 -> {210}; 210 -> {211}; 211 -> {212}; - 212 -> {213}; - 213 -> {214}; - 214 -> {215}; - 215 -> {217}; - 216 -> {218}; - 217 -> {218} [color=green]; - 217 -> {239} [color=red]; - 218 -> {219}; + 212 -> {214}; + 213 -> {215}; + 214 -> {215} [color=green]; + 214 -> {236} [color=red]; + 215 -> {216}; + 216 -> {217}; + 217 -> {218}; + 218 -> {219 236}; 219 -> {220}; 220 -> {221}; - 221 -> {222 239}; + 221 -> {222}; 222 -> {223}; - 223 -> {224}; + 223 -> {224 232}; + 223 -> {233} [style=dotted]; + 223 -> {224} [style=dashed]; 224 -> {225}; 225 -> {226}; - 226 -> {227 235}; - 226 -> {236} [style=dotted]; - 226 -> {227} [style=dashed]; + 226 -> {227}; 227 -> {228}; 228 -> {229}; 229 -> {230}; 230 -> {231}; - 231 -> {232}; - 232 -> {233}; - 233 -> {234}; - 234 -> {236}; + 231 -> {233}; + 232 -> {234}; + 233 -> {234} [color=green]; + 233 -> {237} [color=red label="Postponed"]; + 234 -> {235}; 235 -> {237}; - 236 -> {237} [color=green]; - 236 -> {240} [color=red]; + 236 -> {237} [color=red label="Postponed"]; 237 -> {238}; - 238 -> {240}; - 239 -> {240} [color=red]; + 238 -> {239}; + 239 -> {240}; 240 -> {241}; 241 -> {242}; 242 -> {243}; 243 -> {244}; - 244 -> {245}; - 245 -> {246}; - 246 -> {247}; subgraph cluster_71 { color=red - 248 [label="Enter function test5" style="filled" fillcolor=red]; + 245 [label="Enter function test5" style="filled" fillcolor=red]; subgraph cluster_72 { color=blue - 249 [label="Enter block"]; + 246 [label="Enter block"]; subgraph cluster_73 { color=blue - 250 [label="Function call arguments enter"]; - 251 [label="Access variable R|/y|"]; - 252 [label="Enter safe call"]; + 247 [label="Function call arguments enter"]; + 248 [label="Access variable R|/y|"]; + 249 [label="Enter safe call"]; subgraph cluster_74 { color=blue - 253 [label="Function call arguments enter"]; - 254 [label="Postponed enter to lambda"]; + 250 [label="Function call arguments enter"]; + 251 [label="Postponed enter to lambda"]; subgraph cluster_75 { color=blue - 255 [label="Enter function " style="filled" fillcolor=red]; + 252 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_76 { color=blue - 256 [label="Enter block"]; - 257 [label="Access variable R|/x|"]; - 258 [label="Type operator: (R|/x| as R|kotlin/String|)"]; + 253 [label="Enter block"]; + 254 [label="Access variable R|/x|"]; + 255 [label="Type operator: (R|/x| as R|kotlin/String|)"]; subgraph cluster_77 { color=blue - 259 [label="Function call arguments enter"]; - 260 [label="Function call arguments exit"]; + 256 [label="Function call arguments enter"]; + 257 [label="Function call arguments exit"]; } - 261 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 262 [label="Exit block"]; + 258 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 259 [label="Exit block"]; } - 263 [label="Exit function " style="filled" fillcolor=red]; + 260 [label="Exit function " style="filled" fillcolor=red]; } - 264 [label="Function call arguments exit"]; + 261 [label="Function call arguments exit"]; } - 265 [label="Postponed exit from lambda"]; - 266 [label="Function call: $subj$.R|kotlin/let|(...)" style="filled" fillcolor=yellow]; - 267 [label="Exit safe call"]; - 268 [label="Const: Int(1)"]; + 262 [label="Postponed exit from lambda"]; + 263 [label="Function call: $subj$.R|kotlin/let|(...)" style="filled" fillcolor=yellow]; + 264 [label="Exit safe call"]; + 265 [label="Const: Int(1)"]; subgraph cluster_78 { color=blue - 269 [label="Function call arguments enter"]; - 270 [label="Postponed enter to lambda"]; + 266 [label="Function call arguments enter"]; + 267 [label="Postponed enter to lambda"]; subgraph cluster_79 { color=blue - 271 [label="Enter function " style="filled" fillcolor=red]; + 268 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_80 { color=blue - 272 [label="Enter block"]; - 273 [label="Const: String()"]; - 274 [label="Exit block"]; + 269 [label="Enter block"]; + 270 [label="Const: String()"]; + 271 [label="Exit block"]; } - 275 [label="Exit function " style="filled" fillcolor=red]; + 272 [label="Exit function " style="filled" fillcolor=red]; } - 276 [label="Function call arguments exit"]; + 273 [label="Function call arguments exit"]; } - 277 [label="Postponed exit from lambda"]; - 278 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 279 [label="Function call arguments exit"]; + 274 [label="Postponed exit from lambda"]; + 275 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 276 [label="Function call arguments exit"]; } - 280 [label="Merge postponed lambda exits"]; - 281 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 282 [label="Access variable R|/x|"]; - 283 [label="Access variable R|kotlin/String.length#|"]; - 284 [label="Exit block"]; + 277 [label="Merge postponed lambda exits"]; + 278 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 279 [label="Access variable R|/x|"]; + 280 [label="Access variable R|kotlin/String.length#|"]; + 281 [label="Exit block"]; } - 285 [label="Exit function test5" style="filled" fillcolor=red]; + 282 [label="Exit function test5" style="filled" fillcolor=red]; } - 248 -> {249}; + 245 -> {246}; + 246 -> {247}; + 247 -> {248}; + 248 -> {249 264}; 249 -> {250}; 250 -> {251}; - 251 -> {252 267}; + 251 -> {252 261}; + 251 -> {262} [style=dotted]; + 251 -> {252} [style=dashed]; 252 -> {253}; 253 -> {254}; - 254 -> {255 264}; - 254 -> {265} [style=dotted]; - 254 -> {255} [style=dashed]; + 254 -> {255}; 255 -> {256}; 256 -> {257}; 257 -> {258}; 258 -> {259}; 259 -> {260}; - 260 -> {261}; - 261 -> {262}; - 262 -> {263}; - 263 -> {265}; - 264 -> {266}; - 265 -> {266} [color=green]; - 265 -> {280} [color=red]; + 260 -> {262}; + 261 -> {263}; + 262 -> {263} [color=green]; + 262 -> {277} [color=red]; + 263 -> {264}; + 264 -> {265 277}; + 265 -> {266}; 266 -> {267}; - 267 -> {268 280}; + 267 -> {268 273}; + 267 -> {274} [style=dotted]; + 267 -> {268} [style=dashed]; 268 -> {269}; 269 -> {270}; - 270 -> {271 276}; - 270 -> {277} [style=dotted]; - 270 -> {271} [style=dashed]; + 270 -> {271}; 271 -> {272}; - 272 -> {273}; - 273 -> {274}; - 274 -> {275}; - 275 -> {277}; + 272 -> {274}; + 273 -> {275}; + 274 -> {275} [color=green]; + 274 -> {278} [color=red label="Postponed"]; + 275 -> {276}; 276 -> {278}; - 277 -> {278} [color=green]; - 277 -> {281} [color=red]; + 277 -> {278} [color=red label="Postponed"]; 278 -> {279}; - 279 -> {281}; - 280 -> {281} [color=red]; + 279 -> {280}; + 280 -> {281}; 281 -> {282}; - 282 -> {283}; - 283 -> {284}; - 284 -> {285}; subgraph cluster_81 { color=red - 286 [label="Enter function test6" style="filled" fillcolor=red]; + 283 [label="Enter function test6" style="filled" fillcolor=red]; subgraph cluster_82 { color=blue - 287 [label="Enter block"]; + 284 [label="Enter block"]; subgraph cluster_83 { color=blue - 288 [label="Function call arguments enter"]; + 285 [label="Function call arguments enter"]; subgraph cluster_84 { color=blue - 289 [label="Function call arguments enter"]; + 286 [label="Function call arguments enter"]; subgraph cluster_85 { color=blue - 290 [label="Enter when"]; + 287 [label="Enter when"]; subgraph cluster_86 { color=blue - 291 [label="Enter when branch condition "]; - 292 [label="Const: Boolean(true)"]; - 293 [label="Exit when branch condition"]; + 288 [label="Enter when branch condition "]; + 289 [label="Const: Boolean(true)"]; + 290 [label="Exit when branch condition"]; } subgraph cluster_87 { color=blue - 294 [label="Enter when branch condition else"]; - 295 [label="Exit when branch condition"]; + 291 [label="Enter when branch condition else"]; + 292 [label="Exit when branch condition"]; } - 296 [label="Enter when branch result"]; + 293 [label="Enter when branch result"]; subgraph cluster_88 { color=blue - 297 [label="Enter block"]; + 294 [label="Enter block"]; subgraph cluster_89 { color=blue - 298 [label="Function call arguments enter"]; - 299 [label="Postponed enter to lambda"]; + 295 [label="Function call arguments enter"]; + 296 [label="Postponed enter to lambda"]; subgraph cluster_90 { color=blue - 300 [label="Enter function " style="filled" fillcolor=red]; + 297 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_91 { color=blue - 301 [label="Enter block"]; - 302 [label="Access variable R|/x|"]; - 303 [label="Type operator: (R|/x| as R|kotlin/String|)"]; + 298 [label="Enter block"]; + 299 [label="Access variable R|/x|"]; + 300 [label="Type operator: (R|/x| as R|kotlin/String|)"]; subgraph cluster_92 { color=blue - 304 [label="Function call arguments enter"]; - 305 [label="Function call arguments exit"]; + 301 [label="Function call arguments enter"]; + 302 [label="Function call arguments exit"]; } - 306 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 307 [label="Exit block"]; + 303 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 304 [label="Exit block"]; } - 308 [label="Exit function " style="filled" fillcolor=red]; + 305 [label="Exit function " style="filled" fillcolor=red]; } - 309 [label="Function call arguments exit"]; + 306 [label="Function call arguments exit"]; } - 310 [label="Postponed exit from lambda"]; - 311 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 312 [label="Exit block"]; + 307 [label="Postponed exit from lambda"]; + 308 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 309 [label="Exit block"]; } - 313 [label="Exit when branch result"]; - 314 [label="Enter when branch result"]; + 310 [label="Exit when branch result"]; + 311 [label="Enter when branch result"]; subgraph cluster_93 { color=blue - 315 [label="Enter block"]; + 312 [label="Enter block"]; subgraph cluster_94 { color=blue - 316 [label="Function call arguments enter"]; - 317 [label="Postponed enter to lambda"]; + 313 [label="Function call arguments enter"]; + 314 [label="Postponed enter to lambda"]; subgraph cluster_95 { color=blue - 318 [label="Enter function " style="filled" fillcolor=red]; + 315 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_96 { color=blue - 319 [label="Enter block"]; - 320 [label="Access variable R|/x|"]; - 321 [label="Type operator: (R|/x| as R|kotlin/String|)"]; + 316 [label="Enter block"]; + 317 [label="Access variable R|/x|"]; + 318 [label="Type operator: (R|/x| as R|kotlin/String|)"]; subgraph cluster_97 { color=blue - 322 [label="Function call arguments enter"]; - 323 [label="Function call arguments exit"]; + 319 [label="Function call arguments enter"]; + 320 [label="Function call arguments exit"]; } - 324 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 325 [label="Exit block"]; + 321 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 322 [label="Exit block"]; } - 326 [label="Exit function " style="filled" fillcolor=red]; + 323 [label="Exit function " style="filled" fillcolor=red]; } - 327 [label="Function call arguments exit"]; + 324 [label="Function call arguments exit"]; } - 328 [label="Postponed exit from lambda"]; - 329 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 330 [label="Exit block"]; + 325 [label="Postponed exit from lambda"]; + 326 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 327 [label="Exit block"]; } - 331 [label="Exit when branch result"]; - 332 [label="Exit when"]; + 328 [label="Exit when branch result"]; + 329 [label="Exit when"]; } - 333 [label="Function call arguments exit"]; + 330 [label="Function call arguments exit"]; } - 334 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 335 [label="Const: Int(1)"]; + 331 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 332 [label="Const: Int(1)"]; subgraph cluster_98 { color=blue - 336 [label="Function call arguments enter"]; - 337 [label="Postponed enter to lambda"]; + 333 [label="Function call arguments enter"]; + 334 [label="Postponed enter to lambda"]; subgraph cluster_99 { color=blue - 338 [label="Enter function " style="filled" fillcolor=red]; + 335 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_100 { color=blue - 339 [label="Enter block"]; - 340 [label="Access variable R|/x|"]; - 341 [label="Access variable R|kotlin/String.length#|"]; - 342 [label="Const: Int(123)"]; - 343 [label="Exit block"]; + 336 [label="Enter block"]; + 337 [label="Access variable R|/x|"]; + 338 [label="Access variable R|kotlin/String.length#|"]; + 339 [label="Const: Int(123)"]; + 340 [label="Exit block"]; } - 344 [label="Exit function " style="filled" fillcolor=red]; + 341 [label="Exit function " style="filled" fillcolor=red]; } - 345 [label="Function call arguments exit"]; + 342 [label="Function call arguments exit"]; } - 346 [label="Postponed exit from lambda"]; - 347 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 348 [label="Function call arguments exit"]; + 343 [label="Postponed exit from lambda"]; + 344 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 345 [label="Function call arguments exit"]; } - 349 [label="Merge postponed lambda exits"]; - 350 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 351 [label="Access variable R|/x|"]; - 352 [label="Access variable R|kotlin/String.length#|"]; - 353 [label="Exit block"]; + 346 [label="Merge postponed lambda exits"]; + 347 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 348 [label="Access variable R|/x|"]; + 349 [label="Access variable R|kotlin/String.length#|"]; + 350 [label="Exit block"]; } - 354 [label="Exit function test6" style="filled" fillcolor=red]; + 351 [label="Exit function test6" style="filled" fillcolor=red]; } + 283 -> {284}; + 284 -> {285}; + 285 -> {286}; 286 -> {287}; 287 -> {288}; 288 -> {289}; 289 -> {290}; - 290 -> {291}; + 290 -> {291 311}; 291 -> {292}; 292 -> {293}; - 293 -> {294 314}; + 293 -> {294}; 294 -> {295}; 295 -> {296}; - 296 -> {297}; + 296 -> {297 306}; + 296 -> {307} [style=dotted]; + 296 -> {297} [style=dashed]; 297 -> {298}; 298 -> {299}; - 299 -> {300 309}; - 299 -> {310} [style=dotted]; - 299 -> {300} [style=dashed]; + 299 -> {300}; 300 -> {301}; 301 -> {302}; 302 -> {303}; 303 -> {304}; 304 -> {305}; - 305 -> {306}; - 306 -> {307}; - 307 -> {308}; - 308 -> {310}; - 309 -> {311}; - 310 -> {311} [color=green]; - 310 -> {349} [color=red]; + 305 -> {307}; + 306 -> {308}; + 307 -> {308} [color=green]; + 307 -> {346} [color=red]; + 308 -> {309}; + 309 -> {310}; + 310 -> {329}; 311 -> {312}; 312 -> {313}; - 313 -> {332}; - 314 -> {315}; + 313 -> {314}; + 314 -> {315 324}; + 314 -> {325} [style=dotted]; + 314 -> {315} [style=dashed]; 315 -> {316}; 316 -> {317}; - 317 -> {318 327}; - 317 -> {328} [style=dotted]; - 317 -> {318} [style=dashed]; + 317 -> {318}; 318 -> {319}; 319 -> {320}; 320 -> {321}; 321 -> {322}; 322 -> {323}; - 323 -> {324}; - 324 -> {325}; - 325 -> {326}; - 326 -> {328}; - 327 -> {329}; - 328 -> {329} [color=green]; - 328 -> {349} [color=red]; - 329 -> {330}; + 323 -> {325}; + 324 -> {326}; + 325 -> {326} [color=green]; + 325 -> {346} [color=red]; + 326 -> {327}; + 327 -> {328}; + 328 -> {329}; + 329 -> {330 346}; 330 -> {331}; 331 -> {332}; - 332 -> {333 349}; + 332 -> {333}; 333 -> {334}; - 334 -> {335}; + 334 -> {335 342}; + 334 -> {343} [style=dotted]; + 334 -> {335} [style=dashed]; 335 -> {336}; 336 -> {337}; - 337 -> {338 345}; - 337 -> {346} [style=dotted]; - 337 -> {338} [style=dashed]; + 337 -> {338}; 338 -> {339}; 339 -> {340}; 340 -> {341}; - 341 -> {342}; - 342 -> {343}; - 343 -> {344}; - 344 -> {346}; + 341 -> {343}; + 342 -> {344}; + 343 -> {344} [color=green]; + 343 -> {347} [color=red label="Postponed"]; + 344 -> {345}; 345 -> {347}; - 346 -> {347} [color=green]; - 346 -> {350} [color=red]; + 346 -> {347} [color=red label="Postponed"]; 347 -> {348}; - 348 -> {350}; - 349 -> {350} [color=red]; + 348 -> {349}; + 349 -> {350}; 350 -> {351}; - 351 -> {352}; - 352 -> {353}; - 353 -> {354}; subgraph cluster_101 { color=red - 355 [label="Enter function test7" style="filled" fillcolor=red]; + 352 [label="Enter function test7" style="filled" fillcolor=red]; subgraph cluster_102 { color=blue - 356 [label="Enter block"]; - 357 [label="Access variable R|/x|"]; - 358 [label="Variable declaration: lvar p: R|kotlin/String?|"]; + 353 [label="Enter block"]; + 354 [label="Access variable R|/x|"]; + 355 [label="Variable declaration: lvar p: R|kotlin/String?|"]; subgraph cluster_103 { color=blue - 359 [label="Enter when"]; + 356 [label="Enter when"]; subgraph cluster_104 { color=blue - 360 [label="Enter when branch condition "]; - 361 [label="Access variable R|/p|"]; - 362 [label="Const: Null(null)"]; - 363 [label="Equality operator !="]; - 364 [label="Exit when branch condition"]; + 357 [label="Enter when branch condition "]; + 358 [label="Access variable R|/p|"]; + 359 [label="Const: Null(null)"]; + 360 [label="Equality operator !="]; + 361 [label="Exit when branch condition"]; } - 365 [label="Synthetic else branch"]; - 366 [label="Enter when branch result"]; + 362 [label="Synthetic else branch"]; + 363 [label="Enter when branch result"]; subgraph cluster_105 { color=blue - 367 [label="Enter block"]; + 364 [label="Enter block"]; subgraph cluster_106 { color=blue - 368 [label="Function call arguments enter"]; + 365 [label="Function call arguments enter"]; subgraph cluster_107 { color=blue - 369 [label="Function call arguments enter"]; + 366 [label="Function call arguments enter"]; subgraph cluster_108 { color=blue - 370 [label="Function call arguments enter"]; - 371 [label="Postponed enter to lambda"]; + 367 [label="Function call arguments enter"]; + 368 [label="Postponed enter to lambda"]; subgraph cluster_109 { color=blue - 372 [label="Enter function " style="filled" fillcolor=red]; + 369 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_110 { color=blue - 373 [label="Enter block"]; - 374 [label="Const: Null(null)"]; - 375 [label="Assignment: R|/p|"]; + 370 [label="Enter block"]; + 371 [label="Const: Null(null)"]; + 372 [label="Assignment: R|/p|"]; subgraph cluster_111 { color=blue - 376 [label="Function call arguments enter"]; - 377 [label="Function call arguments exit"]; + 373 [label="Function call arguments enter"]; + 374 [label="Function call arguments exit"]; } - 378 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 379 [label="Exit block"]; + 375 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 376 [label="Exit block"]; } - 380 [label="Exit function " style="filled" fillcolor=red]; + 377 [label="Exit function " style="filled" fillcolor=red]; } - 381 [label="Function call arguments exit"]; + 378 [label="Function call arguments exit"]; } - 382 [label="Postponed exit from lambda"]; - 383 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 384 [label="Function call arguments exit"]; + 379 [label="Postponed exit from lambda"]; + 380 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 381 [label="Function call arguments exit"]; } - 385 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; - 386 [label="Const: Int(1)"]; + 382 [label="Function call: R|/id|(...)" style="filled" fillcolor=yellow]; + 383 [label="Const: Int(1)"]; subgraph cluster_112 { color=blue - 387 [label="Function call arguments enter"]; - 388 [label="Postponed enter to lambda"]; + 384 [label="Function call arguments enter"]; + 385 [label="Postponed enter to lambda"]; subgraph cluster_113 { color=blue - 389 [label="Enter function " style="filled" fillcolor=red]; + 386 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_114 { color=blue - 390 [label="Enter block"]; - 391 [label="Access variable R|/p|"]; - 392 [label="Smart cast: R|/p|"]; - 393 [label="Access variable R|kotlin/String.length#|"]; - 394 [label="Const: Int(123)"]; - 395 [label="Exit block"]; + 387 [label="Enter block"]; + 388 [label="Access variable R|/p|"]; + 389 [label="Smart cast: R|/p|"]; + 390 [label="Access variable R|kotlin/String.length#|"]; + 391 [label="Const: Int(123)"]; + 392 [label="Exit block"]; } - 396 [label="Exit function " style="filled" fillcolor=red]; + 393 [label="Exit function " style="filled" fillcolor=red]; } - 397 [label="Function call arguments exit"]; + 394 [label="Function call arguments exit"]; } - 398 [label="Postponed exit from lambda"]; - 399 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; - 400 [label="Function call arguments exit"]; + 395 [label="Postponed exit from lambda"]; + 396 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 397 [label="Function call arguments exit"]; } - 401 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; - 402 [label="Access variable R|/p|"]; - 403 [label="Smart cast: R|/p|"]; - 404 [label="Access variable R|kotlin/String.length#|"]; - 405 [label="Exit block"]; + 398 [label="Function call: R|/foo|(...)" style="filled" fillcolor=yellow]; + 399 [label="Access variable R|/p|"]; + 400 [label="Access variable R|kotlin/String.length#|"]; + 401 [label="Exit block"]; } - 406 [label="Exit when branch result"]; - 407 [label="Exit when"]; + 402 [label="Exit when branch result"]; + 403 [label="Exit when"]; } - 408 [label="Exit block"]; + 404 [label="Exit block"]; } - 409 [label="Exit function test7" style="filled" fillcolor=red]; + 405 [label="Exit function test7" style="filled" fillcolor=red]; } + 352 -> {353}; + 353 -> {354}; + 354 -> {355}; 355 -> {356}; 356 -> {357}; 357 -> {358}; 358 -> {359}; 359 -> {360}; 360 -> {361}; - 361 -> {362}; - 362 -> {363}; + 361 -> {362 363}; + 362 -> {403}; 363 -> {364}; - 364 -> {365 366}; - 365 -> {407}; + 364 -> {365}; + 365 -> {366}; 366 -> {367}; 367 -> {368}; - 368 -> {369}; + 368 -> {369 378}; + 368 -> {379} [style=dotted]; + 368 -> {369} [style=dashed]; 369 -> {370}; 370 -> {371}; - 371 -> {372 381}; - 371 -> {382} [style=dotted]; - 371 -> {372} [style=dashed]; + 371 -> {372}; 372 -> {373}; 373 -> {374}; 374 -> {375}; 375 -> {376}; 376 -> {377}; - 377 -> {378}; - 378 -> {379}; - 379 -> {380}; - 380 -> {382}; - 381 -> {383}; - 382 -> {383} [color=green]; - 382 -> {401} [color=red]; + 377 -> {379}; + 378 -> {380}; + 379 -> {380} [color=green]; + 379 -> {398} [color=red label="Postponed"]; + 380 -> {381}; + 381 -> {382}; + 382 -> {383}; 383 -> {384}; 384 -> {385}; - 385 -> {386}; + 385 -> {386 394}; + 385 -> {395} [style=dotted]; + 385 -> {386} [style=dashed]; 386 -> {387}; 387 -> {388}; - 388 -> {389 397}; - 388 -> {398} [style=dotted]; - 388 -> {389} [style=dashed]; + 388 -> {389}; 389 -> {390}; 390 -> {391}; 391 -> {392}; 392 -> {393}; - 393 -> {394}; - 394 -> {395}; - 395 -> {396}; - 396 -> {398}; - 397 -> {399}; - 398 -> {399} [color=green]; - 398 -> {401} [color=red]; + 393 -> {395}; + 394 -> {396}; + 395 -> {396} [color=green]; + 395 -> {398} [color=red label="Postponed"]; + 396 -> {397}; + 397 -> {398}; + 398 -> {399}; 399 -> {400}; 400 -> {401}; 401 -> {402}; 402 -> {403}; 403 -> {404}; 404 -> {405}; - 405 -> {406}; - 406 -> {407}; - 407 -> {408}; - 408 -> {409}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.fir.txt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.fir.txt index 65d823c45f1..67915efc0b7 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.fir.txt @@ -20,7 +20,7 @@ FILE: flowFromInplaceLambda2.kt ^ Int(123) } )) - R|/x|.R|kotlin/String.length| + R|/x|.R|kotlin/String.length#| } public final fun test2(x: R|kotlin/String?|): R|kotlin/Unit| { R|/foo|(R|/id|(R|kotlin/run|( = run@fun (): R|kotlin/Int?| { @@ -32,7 +32,7 @@ FILE: flowFromInplaceLambda2.kt ^ Int(123) } )) - R|/x|.R|kotlin/String.length| + R|/x|.R|kotlin/String.length#| } public final fun test3(x: R|kotlin/String?|): R|kotlin/Unit| { R|/foo|(R|/id|(R|kotlin/run|( = run@fun (): R|kotlin/Int?| { @@ -52,7 +52,7 @@ FILE: flowFromInplaceLambda2.kt ^ Int(123) } )) - R|/x|.R|kotlin/String.length| + R|/x|.R|kotlin/String.length#| } public final fun test4(x: R|kotlin/String?|): R|kotlin/Unit| { lvar p: R|kotlin/String?| = R|/x| diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.kt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.kt index 62c3af36a3e..8aa384efedc 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.kt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda2.kt @@ -14,7 +14,7 @@ fun test1(x: String?) { 1, run { x.length; 123 } // Bad (resolution order undefined) ) - x.length // OK (x as String unconditional) + x.length // Bad: KT-37838 -> OK (x as String unconditional) } fun test2(x: String?) { @@ -23,7 +23,7 @@ fun test2(x: String?) { someCompletedCall(1), run { x.length; 123 } // Bad (resolution order undefined) ) - x.length // OK (x as String unconditional) + x.length // OK (x as String unconditional) } fun test3(x: String?) { @@ -32,7 +32,7 @@ fun test3(x: String?) { if (true) 1 else 2, run { x.length; 123 } // Bad (resolution order undefined) ) - x.length // OK (x as String unconditional) + x.length // Bad: KT-37838 -> OK (x as String unconditional) } fun test4(x: String?) { @@ -62,7 +62,7 @@ fun test6(x: String?) { 1, run { x.length; 123 } // Bad (resolution order undefined) ) - x.length // OK (x as String in both branches) + x.length // Bad: KT-37838 -> OK (x as String in both branches) } fun test7(x: String?) { diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.dot index 66fb7c6cfe3..822994df9b8 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.dot @@ -154,19 +154,17 @@ digraph flowFromInplaceLambda3_kt { 52 [label="Postponed exit from lambda"]; 53 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; 54 [label="Access variable R|/x|"]; - 55 [label="Smart cast: R|/x|"]; - 56 [label="Access variable #"]; + 55 [label="Access variable #"]; subgraph cluster_21 { color=blue - 57 [label="Function call arguments enter"]; - 58 [label="Access variable R|/x|"]; - 59 [label="Smart cast: R|/x|"]; - 60 [label="Function call arguments exit"]; + 56 [label="Function call arguments enter"]; + 57 [label="Access variable R|/x|"]; + 58 [label="Function call arguments exit"]; } - 61 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - 62 [label="Exit block"]; + 59 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 60 [label="Exit block"]; } - 63 [label="Exit function test1" style="filled" fillcolor=red]; + 61 [label="Exit function test1" style="filled" fillcolor=red]; } 35 -> {36}; 36 -> {37}; @@ -186,8 +184,8 @@ digraph flowFromInplaceLambda3_kt { 49 -> {50}; 50 -> {52}; 51 -> {53}; - 52 -> {53}; 52 -> {44} [color=green style=dashed]; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55}; 55 -> {56}; @@ -196,48 +194,47 @@ digraph flowFromInplaceLambda3_kt { 58 -> {59}; 59 -> {60}; 60 -> {61}; - 61 -> {62}; - 62 -> {63}; subgraph cluster_22 { color=red - 64 [label="Enter function test1m" style="filled" fillcolor=red]; + 62 [label="Enter function test1m" style="filled" fillcolor=red]; subgraph cluster_23 { color=blue - 65 [label="Enter block"]; - 66 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; - 67 [label="Const: String()"]; - 68 [label="Assignment: R|/x|"]; - 69 [label="Access variable R|/x|"]; - 70 [label="Smart cast: R|/x|"]; - 71 [label="Access variable R|kotlin/String.length|"]; + 63 [label="Enter block"]; + 64 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; + 65 [label="Const: String()"]; + 66 [label="Assignment: R|/x|"]; + 67 [label="Access variable R|/x|"]; + 68 [label="Smart cast: R|/x|"]; + 69 [label="Access variable R|kotlin/String.length|"]; subgraph cluster_24 { color=blue - 72 [label="Function call arguments enter"]; - 73 [label="Postponed enter to lambda"]; + 70 [label="Function call arguments enter"]; + 71 [label="Postponed enter to lambda"]; subgraph cluster_25 { color=blue - 74 [label="Enter function " style="filled" fillcolor=red]; + 72 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_26 { color=blue - 75 [label="Enter block"]; - 76 [label="Const: String()"]; - 77 [label="Assignment: R|/x|"]; - 78 [label="Exit block"]; + 73 [label="Enter block"]; + 74 [label="Const: String()"]; + 75 [label="Assignment: R|/x|"]; + 76 [label="Exit block"]; } - 79 [label="Exit function " style="filled" fillcolor=red]; + 77 [label="Exit function " style="filled" fillcolor=red]; } - 80 [label="Function call arguments exit"]; + 78 [label="Function call arguments exit"]; } - 81 [label="Postponed exit from lambda"]; - 82 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; - 83 [label="Access variable R|/x|"]; - 84 [label="Smart cast: R|/x|"]; - 85 [label="Access variable R|kotlin/String.length|"]; - 86 [label="Exit block"]; + 79 [label="Postponed exit from lambda"]; + 80 [label="Function call: R|/unknown|(...)" style="filled" fillcolor=yellow]; + 81 [label="Access variable R|/x|"]; + 82 [label="Access variable #"]; + 83 [label="Exit block"]; } - 87 [label="Exit function test1m" style="filled" fillcolor=red]; + 84 [label="Exit function test1m" style="filled" fillcolor=red]; } + 62 -> {63}; + 63 -> {64}; 64 -> {65}; 65 -> {66}; 66 -> {67}; @@ -245,257 +242,242 @@ digraph flowFromInplaceLambda3_kt { 68 -> {69}; 69 -> {70}; 70 -> {71}; - 71 -> {72}; + 71 -> {72 78 79}; + 71 -> {72} [style=dashed]; 72 -> {73}; - 73 -> {74 80 81}; - 73 -> {74} [style=dashed]; + 73 -> {74}; 74 -> {75}; 75 -> {76}; 76 -> {77}; - 77 -> {78}; - 78 -> {79}; - 79 -> {81}; - 80 -> {82}; + 77 -> {79}; + 78 -> {80}; + 79 -> {71} [color=green style=dashed]; + 79 -> {80} [label="Postponed"]; + 80 -> {81}; 81 -> {82}; - 81 -> {73} [color=green style=dashed]; 82 -> {83}; 83 -> {84}; - 84 -> {85}; - 85 -> {86}; - 86 -> {87}; subgraph cluster_27 { color=red - 88 [label="Enter function test2" style="filled" fillcolor=red]; + 85 [label="Enter function test2" style="filled" fillcolor=red]; subgraph cluster_28 { color=blue - 89 [label="Enter block"]; - 90 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; - 91 [label="Const: String()"]; - 92 [label="Assignment: R|/x|"]; - 93 [label="Access variable R|/x|"]; - 94 [label="Smart cast: R|/x|"]; - 95 [label="Access variable R|kotlin/String.length|"]; + 86 [label="Enter block"]; + 87 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; + 88 [label="Const: String()"]; + 89 [label="Assignment: R|/x|"]; + 90 [label="Access variable R|/x|"]; + 91 [label="Smart cast: R|/x|"]; + 92 [label="Access variable R|kotlin/String.length|"]; subgraph cluster_29 { color=blue - 96 [label="Function call arguments enter"]; - 97 [label="Postponed enter to lambda"]; + 93 [label="Function call arguments enter"]; + 94 [label="Postponed enter to lambda"]; subgraph cluster_30 { color=blue - 98 [label="Enter function " style="filled" fillcolor=red]; + 95 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_31 { color=blue - 99 [label="Enter block"]; - 100 [label="Const: Int(1)"]; - 101 [label="Assignment: R|/x|"]; - 102 [label="Exit block"]; + 96 [label="Enter block"]; + 97 [label="Const: Int(1)"]; + 98 [label="Assignment: R|/x|"]; + 99 [label="Exit block"]; } - 103 [label="Exit function " style="filled" fillcolor=red]; + 100 [label="Exit function " style="filled" fillcolor=red]; } - 104 [label="Function call arguments exit"]; + 101 [label="Function call arguments exit"]; } - 105 [label="Postponed exit from lambda"]; - 106 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; - 107 [label="Access variable R|/x|"]; - 108 [label="Smart cast: R|/x|"]; - 109 [label="Access variable #"]; + 102 [label="Postponed exit from lambda"]; + 103 [label="Function call: R|/atLeastOnce|(...)" style="filled" fillcolor=yellow]; + 104 [label="Access variable R|/x|"]; + 105 [label="Access variable #"]; subgraph cluster_32 { color=blue - 110 [label="Function call arguments enter"]; - 111 [label="Access variable R|/x|"]; - 112 [label="Smart cast: R|/x|"]; - 113 [label="Function call arguments exit"]; + 106 [label="Function call arguments enter"]; + 107 [label="Access variable R|/x|"]; + 108 [label="Function call arguments exit"]; } - 114 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 115 [label="Exit block"]; + 109 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 110 [label="Exit block"]; } - 116 [label="Exit function test2" style="filled" fillcolor=red]; + 111 [label="Exit function test2" style="filled" fillcolor=red]; } + 85 -> {86}; + 86 -> {87}; + 87 -> {88}; 88 -> {89}; 89 -> {90}; 90 -> {91}; 91 -> {92}; 92 -> {93}; 93 -> {94}; - 94 -> {95}; + 94 -> {95 101}; + 94 -> {102} [style=dotted]; + 94 -> {95} [style=dashed]; 95 -> {96}; 96 -> {97}; - 97 -> {98 104}; - 97 -> {105} [style=dotted]; - 97 -> {98} [style=dashed]; + 97 -> {98}; 98 -> {99}; 99 -> {100}; - 100 -> {101}; - 101 -> {102}; - 102 -> {103}; - 103 -> {105}; - 104 -> {106}; + 100 -> {102}; + 101 -> {103}; + 102 -> {94} [color=green style=dashed]; + 102 -> {103} [label="Postponed"]; + 103 -> {104}; + 104 -> {105}; 105 -> {106}; - 105 -> {97} [color=green style=dashed]; 106 -> {107}; 107 -> {108}; 108 -> {109}; 109 -> {110}; 110 -> {111}; - 111 -> {112}; + + subgraph cluster_33 { + color=red + 112 [label="Enter function test3" style="filled" fillcolor=red]; + subgraph cluster_34 { + color=blue + 113 [label="Enter block"]; + 114 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; + 115 [label="Const: String()"]; + 116 [label="Assignment: R|/x|"]; + 117 [label="Access variable R|/x|"]; + 118 [label="Smart cast: R|/x|"]; + 119 [label="Access variable R|kotlin/String.length|"]; + subgraph cluster_35 { + color=blue + 120 [label="Function call arguments enter"]; + 121 [label="Postponed enter to lambda"]; + subgraph cluster_36 { + color=blue + 122 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_37 { + color=blue + 123 [label="Enter block"]; + 124 [label="Const: Int(1)"]; + 125 [label="Assignment: R|/x|"]; + 126 [label="Exit block"]; + } + 127 [label="Exit function " style="filled" fillcolor=red]; + } + 128 [label="Function call arguments exit"]; + } + 129 [label="Postponed exit from lambda"]; + 130 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; + 131 [label="Access variable R|/x|"]; + 132 [label="Access variable #"]; + subgraph cluster_38 { + color=blue + 133 [label="Function call arguments enter"]; + 134 [label="Access variable R|/x|"]; + 135 [label="Function call arguments exit"]; + } + 136 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 137 [label="Exit block"]; + } + 138 [label="Exit function test3" style="filled" fillcolor=red]; + } 112 -> {113}; 113 -> {114}; 114 -> {115}; 115 -> {116}; - - subgraph cluster_33 { - color=red - 117 [label="Enter function test3" style="filled" fillcolor=red]; - subgraph cluster_34 { - color=blue - 118 [label="Enter block"]; - 119 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; - 120 [label="Const: String()"]; - 121 [label="Assignment: R|/x|"]; - 122 [label="Access variable R|/x|"]; - 123 [label="Smart cast: R|/x|"]; - 124 [label="Access variable R|kotlin/String.length|"]; - subgraph cluster_35 { - color=blue - 125 [label="Function call arguments enter"]; - 126 [label="Postponed enter to lambda"]; - subgraph cluster_36 { - color=blue - 127 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_37 { - color=blue - 128 [label="Enter block"]; - 129 [label="Const: Int(1)"]; - 130 [label="Assignment: R|/x|"]; - 131 [label="Exit block"]; - } - 132 [label="Exit function " style="filled" fillcolor=red]; - } - 133 [label="Function call arguments exit"]; - } - 134 [label="Postponed exit from lambda"]; - 135 [label="Function call: R|/exactlyOnce|(...)" style="filled" fillcolor=yellow]; - 136 [label="Access variable R|/x|"]; - 137 [label="Smart cast: R|/x|"]; - 138 [label="Access variable #"]; - subgraph cluster_38 { - color=blue - 139 [label="Function call arguments enter"]; - 140 [label="Access variable R|/x|"]; - 141 [label="Smart cast: R|/x|"]; - 142 [label="Function call arguments exit"]; - } - 143 [label="Function call: R|/x|.R|kotlin/Int.inc|()" style="filled" fillcolor=yellow]; - 144 [label="Exit block"]; - } - 145 [label="Exit function test3" style="filled" fillcolor=red]; - } + 116 -> {117}; 117 -> {118}; 118 -> {119}; 119 -> {120}; 120 -> {121}; - 121 -> {122}; + 121 -> {122 128}; + 121 -> {129} [style=dotted]; + 121 -> {122} [style=dashed]; 122 -> {123}; 123 -> {124}; 124 -> {125}; 125 -> {126}; - 126 -> {127 133}; - 126 -> {134} [style=dotted]; - 126 -> {127} [style=dashed]; - 127 -> {128}; - 128 -> {129}; - 129 -> {130}; + 126 -> {127}; + 127 -> {129}; + 128 -> {130}; + 129 -> {130} [label="Postponed"]; 130 -> {131}; 131 -> {132}; - 132 -> {134}; - 133 -> {135}; + 132 -> {133}; + 133 -> {134}; 134 -> {135}; 135 -> {136}; 136 -> {137}; 137 -> {138}; - 138 -> {139}; + + subgraph cluster_39 { + color=red + 139 [label="Enter function test4" style="filled" fillcolor=red]; + subgraph cluster_40 { + color=blue + 140 [label="Enter block"]; + 141 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; + 142 [label="Const: String()"]; + 143 [label="Assignment: R|/x|"]; + 144 [label="Access variable R|/x|"]; + 145 [label="Smart cast: R|/x|"]; + 146 [label="Access variable R|kotlin/String.length|"]; + subgraph cluster_41 { + color=blue + 147 [label="Function call arguments enter"]; + 148 [label="Postponed enter to lambda"]; + subgraph cluster_42 { + color=blue + 149 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_43 { + color=blue + 150 [label="Enter block"]; + 151 [label="Const: Int(1)"]; + 152 [label="Assignment: R|/x|"]; + 153 [label="Exit block"]; + } + 154 [label="Exit function " style="filled" fillcolor=red]; + } + 155 [label="Function call arguments exit"]; + } + 156 [label="Postponed exit from lambda"]; + 157 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; + 158 [label="Access variable R|/x|"]; + 159 [label="Access variable #"]; + subgraph cluster_44 { + color=blue + 160 [label="Function call arguments enter"]; + 161 [label="Access variable R|/x|"]; + 162 [label="Function call arguments exit"]; + } + 163 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 164 [label="Exit block"]; + } + 165 [label="Exit function test4" style="filled" fillcolor=red]; + } 139 -> {140}; 140 -> {141}; 141 -> {142}; 142 -> {143}; 143 -> {144}; 144 -> {145}; - - subgraph cluster_39 { - color=red - 146 [label="Enter function test4" style="filled" fillcolor=red]; - subgraph cluster_40 { - color=blue - 147 [label="Enter block"]; - 148 [label="Variable declaration: lvar x: R|kotlin/Any?|"]; - 149 [label="Const: String()"]; - 150 [label="Assignment: R|/x|"]; - 151 [label="Access variable R|/x|"]; - 152 [label="Smart cast: R|/x|"]; - 153 [label="Access variable R|kotlin/String.length|"]; - subgraph cluster_41 { - color=blue - 154 [label="Function call arguments enter"]; - 155 [label="Postponed enter to lambda"]; - subgraph cluster_42 { - color=blue - 156 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_43 { - color=blue - 157 [label="Enter block"]; - 158 [label="Const: Int(1)"]; - 159 [label="Assignment: R|/x|"]; - 160 [label="Exit block"]; - } - 161 [label="Exit function " style="filled" fillcolor=red]; - } - 162 [label="Function call arguments exit"]; - } - 163 [label="Postponed exit from lambda"]; - 164 [label="Function call: R|/atMostOnce|(...)" style="filled" fillcolor=yellow]; - 165 [label="Access variable R|/x|"]; - 166 [label="Smart cast: R|/x|"]; - 167 [label="Access variable #"]; - subgraph cluster_44 { - color=blue - 168 [label="Function call arguments enter"]; - 169 [label="Access variable R|/x|"]; - 170 [label="Smart cast: R|/x|"]; - 171 [label="Function call arguments exit"]; - } - 172 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; - 173 [label="Exit block"]; - } - 174 [label="Exit function test4" style="filled" fillcolor=red]; - } + 145 -> {146}; 146 -> {147}; 147 -> {148}; - 148 -> {149}; + 148 -> {149 155 156}; + 148 -> {149} [style=dashed]; 149 -> {150}; 150 -> {151}; 151 -> {152}; 152 -> {153}; 153 -> {154}; - 154 -> {155}; - 155 -> {156 162 163}; - 155 -> {156} [style=dashed]; - 156 -> {157}; + 154 -> {156}; + 155 -> {157}; + 156 -> {157} [label="Postponed"]; 157 -> {158}; 158 -> {159}; 159 -> {160}; 160 -> {161}; - 161 -> {163}; - 162 -> {164}; + 161 -> {162}; + 162 -> {163}; 163 -> {164}; 164 -> {165}; - 165 -> {166}; - 166 -> {167}; - 167 -> {168}; - 168 -> {169}; - 169 -> {170}; - 170 -> {171}; - 171 -> {172}; - 172 -> {173}; - 173 -> {174}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.fir.txt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.fir.txt index 5ec4f3acff6..86a7d442b1f 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.fir.txt @@ -77,7 +77,7 @@ FILE: flowFromInplaceLambda3.kt R|/x| = String() } ) - R|/x|.R|kotlin/String.length| + R|/x|.# } public final fun test2(): R|kotlin/Unit| { lvar x: R|kotlin/Any?| @@ -88,7 +88,7 @@ FILE: flowFromInplaceLambda3.kt } ) R|/x|.# - R|/x|.R|kotlin/Int.inc|() + R|/x|.#() } public final fun test3(): R|kotlin/Unit| { lvar x: R|kotlin/Any?| @@ -99,7 +99,7 @@ FILE: flowFromInplaceLambda3.kt } ) R|/x|.# - R|/x|.R|kotlin/Int.inc|() + R|/x|.#() } public final fun test4(): R|kotlin/Unit| { lvar x: R|kotlin/Any?| diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.kt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.kt index 07010b46c6d..445118fe4fa 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.kt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromInplaceLambda3.kt @@ -36,7 +36,7 @@ fun test1m() { x = "" x.length unknown { x = "" } - x.length + x.length } fun test2() { @@ -45,7 +45,7 @@ fun test2() { x.length atLeastOnce { x = 1 } x.length - x.inc() + x.inc() } fun test3() { @@ -54,7 +54,7 @@ fun test3() { x.length exactlyOnce { x = 1 } x.length - x.inc() + x.inc() } fun test4() { diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.dot index 8b4c9ec9bd5..9cf524fe1a6 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.dot @@ -136,16 +136,15 @@ digraph flowFromTwoInplaceLambdas_kt { 55 [label="Postponed exit from lambda"]; 56 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; 57 [label="Access variable R|/p|"]; - 58 [label="Smart cast: R|/p|"]; - 59 [label="Access variable R|kotlin/String.length#|"]; - 60 [label="Exit block"]; + 58 [label="Access variable R|kotlin/String.length#|"]; + 59 [label="Exit block"]; } - 61 [label="Exit when branch result"]; - 62 [label="Exit when"]; + 60 [label="Exit when branch result"]; + 61 [label="Exit when"]; } - 63 [label="Exit block"]; + 62 [label="Exit block"]; } - 64 [label="Exit function test1" style="filled" fillcolor=red]; + 63 [label="Exit function test1" style="filled" fillcolor=red]; } 21 -> {22}; 22 -> {23}; @@ -157,7 +156,7 @@ digraph flowFromTwoInplaceLambdas_kt { 28 -> {29}; 29 -> {30}; 30 -> {31 32}; - 31 -> {62}; + 31 -> {61}; 32 -> {33}; 33 -> {34}; 34 -> {35}; @@ -182,8 +181,8 @@ digraph flowFromTwoInplaceLambdas_kt { 51 -> {52}; 52 -> {55}; 53 -> {56}; - 54 -> {56}; - 55 -> {56}; + 54 -> {56} [label="Postponed"]; + 55 -> {56} [label="Postponed"]; 56 -> {57}; 57 -> {58}; 58 -> {59}; @@ -191,85 +190,84 @@ digraph flowFromTwoInplaceLambdas_kt { 60 -> {61}; 61 -> {62}; 62 -> {63}; - 63 -> {64}; subgraph cluster_19 { color=red - 65 [label="Enter function test1_tail" style="filled" fillcolor=red]; + 64 [label="Enter function test1_tail" style="filled" fillcolor=red]; subgraph cluster_20 { color=blue - 66 [label="Enter block"]; - 67 [label="Access variable R|/x|"]; - 68 [label="Variable declaration: lvar p: R|kotlin/String?|"]; + 65 [label="Enter block"]; + 66 [label="Access variable R|/x|"]; + 67 [label="Variable declaration: lvar p: R|kotlin/String?|"]; subgraph cluster_21 { color=blue - 69 [label="Enter when"]; + 68 [label="Enter when"]; subgraph cluster_22 { color=blue - 70 [label="Enter when branch condition "]; - 71 [label="Access variable R|/p|"]; - 72 [label="Const: Null(null)"]; - 73 [label="Equality operator !="]; - 74 [label="Exit when branch condition"]; + 69 [label="Enter when branch condition "]; + 70 [label="Access variable R|/p|"]; + 71 [label="Const: Null(null)"]; + 72 [label="Equality operator !="]; + 73 [label="Exit when branch condition"]; } - 75 [label="Synthetic else branch"]; - 76 [label="Enter when branch result"]; + 74 [label="Synthetic else branch"]; + 75 [label="Enter when branch result"]; subgraph cluster_23 { color=blue - 77 [label="Enter block"]; + 76 [label="Enter block"]; subgraph cluster_24 { color=blue - 78 [label="Function call arguments enter"]; - 79 [label="Postponed enter to lambda"]; + 77 [label="Function call arguments enter"]; + 78 [label="Postponed enter to lambda"]; subgraph cluster_25 { color=blue - 80 [label="Enter function " style="filled" fillcolor=red]; + 79 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_26 { color=blue - 81 [label="Enter block"]; - 82 [label="Access variable R|/p|"]; - 83 [label="Smart cast: R|/p|"]; - 84 [label="Access variable R|kotlin/String.length#|"]; - 85 [label="Const: Int(123)"]; - 86 [label="Exit block"]; + 80 [label="Enter block"]; + 81 [label="Access variable R|/p|"]; + 82 [label="Smart cast: R|/p|"]; + 83 [label="Access variable R|kotlin/String.length#|"]; + 84 [label="Const: Int(123)"]; + 85 [label="Exit block"]; } - 87 [label="Exit function " style="filled" fillcolor=red]; + 86 [label="Exit function " style="filled" fillcolor=red]; } subgraph cluster_27 { color=blue - 88 [label="Enter function " style="filled" fillcolor=red]; + 87 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_28 { color=blue - 89 [label="Enter block"]; - 90 [label="Const: Null(null)"]; - 91 [label="Assignment: R|/p|"]; + 88 [label="Enter block"]; + 89 [label="Const: Null(null)"]; + 90 [label="Assignment: R|/p|"]; subgraph cluster_29 { color=blue - 92 [label="Function call arguments enter"]; - 93 [label="Function call arguments exit"]; + 91 [label="Function call arguments enter"]; + 92 [label="Function call arguments exit"]; } - 94 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 95 [label="Exit block"]; + 93 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 94 [label="Exit block"]; } - 96 [label="Exit function " style="filled" fillcolor=red]; + 95 [label="Exit function " style="filled" fillcolor=red]; } - 97 [label="Function call arguments exit"]; + 96 [label="Function call arguments exit"]; } + 97 [label="Postponed exit from lambda"]; 98 [label="Postponed exit from lambda"]; - 99 [label="Postponed exit from lambda"]; - 100 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; - 101 [label="Access variable R|/p|"]; - 102 [label="Smart cast: R|/p|"]; - 103 [label="Access variable R|kotlin/String.length#|"]; - 104 [label="Exit block"]; + 99 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 100 [label="Access variable R|/p|"]; + 101 [label="Access variable R|kotlin/String.length#|"]; + 102 [label="Exit block"]; } - 105 [label="Exit when branch result"]; - 106 [label="Exit when"]; + 103 [label="Exit when branch result"]; + 104 [label="Exit when"]; } - 107 [label="Exit block"]; + 105 [label="Exit block"]; } - 108 [label="Exit function test1_tail" style="filled" fillcolor=red]; + 106 [label="Exit function test1_tail" style="filled" fillcolor=red]; } + 64 -> {65}; 65 -> {66}; 66 -> {67}; 67 -> {68}; @@ -278,23 +276,23 @@ digraph flowFromTwoInplaceLambdas_kt { 70 -> {71}; 71 -> {72}; 72 -> {73}; - 73 -> {74}; - 74 -> {75 76}; - 75 -> {106}; + 73 -> {74 75}; + 74 -> {104}; + 75 -> {76}; 76 -> {77}; 77 -> {78}; - 78 -> {79}; - 79 -> {80 88 97}; - 79 -> {98 99} [style=dotted]; - 79 -> {80 88} [style=dashed]; + 78 -> {79 87 96}; + 78 -> {97 98} [style=dotted]; + 78 -> {79 87} [style=dashed]; + 79 -> {80}; 80 -> {81}; 81 -> {82}; 82 -> {83}; 83 -> {84}; 84 -> {85}; 85 -> {86}; - 86 -> {87}; - 87 -> {98}; + 86 -> {97}; + 87 -> {88}; 88 -> {89}; 89 -> {90}; 90 -> {91}; @@ -302,10 +300,10 @@ digraph flowFromTwoInplaceLambdas_kt { 92 -> {93}; 93 -> {94}; 94 -> {95}; - 95 -> {96}; + 95 -> {98}; 96 -> {99}; - 97 -> {100}; - 98 -> {100}; + 97 -> {99} [label="Postponed"]; + 98 -> {99} [label="Postponed"]; 99 -> {100}; 100 -> {101}; 101 -> {102}; @@ -313,329 +311,383 @@ digraph flowFromTwoInplaceLambdas_kt { 103 -> {104}; 104 -> {105}; 105 -> {106}; - 106 -> {107}; - 107 -> {108}; subgraph cluster_30 { color=red - 109 [label="Enter function test2" style="filled" fillcolor=red]; + 107 [label="Enter function test2" style="filled" fillcolor=red]; subgraph cluster_31 { color=blue - 110 [label="Enter block"]; - 111 [label="Access variable R|/x|"]; - 112 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; - 113 [label="Access variable R|/p|"]; - 114 [label="Access variable #"]; + 108 [label="Enter block"]; + 109 [label="Access variable R|/x|"]; + 110 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; + 111 [label="Access variable R|/p|"]; + 112 [label="Access variable #"]; subgraph cluster_32 { color=blue - 115 [label="Function call arguments enter"]; - 116 [label="Postponed enter to lambda"]; + 113 [label="Function call arguments enter"]; + 114 [label="Postponed enter to lambda"]; subgraph cluster_33 { color=blue - 117 [label="Enter function " style="filled" fillcolor=red]; + 115 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_34 { color=blue - 118 [label="Enter block"]; - 119 [label="Access variable R|/p|"]; - 120 [label="Type operator: (R|/p| as R|kotlin/String|)"]; - 121 [label="Const: Int(123)"]; - 122 [label="Exit block"]; + 116 [label="Enter block"]; + 117 [label="Access variable R|/p|"]; + 118 [label="Type operator: (R|/p| as R|kotlin/String|)"]; + 119 [label="Const: Int(123)"]; + 120 [label="Exit block"]; } - 123 [label="Exit function " style="filled" fillcolor=red]; + 121 [label="Exit function " style="filled" fillcolor=red]; } subgraph cluster_35 { color=blue - 124 [label="Enter function " style="filled" fillcolor=red]; + 122 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_36 { color=blue - 125 [label="Enter block"]; - 126 [label="Const: Null(null)"]; - 127 [label="Assignment: R|/p|"]; + 123 [label="Enter block"]; + 124 [label="Const: Null(null)"]; + 125 [label="Assignment: R|/p|"]; subgraph cluster_37 { color=blue - 128 [label="Function call arguments enter"]; - 129 [label="Function call arguments exit"]; + 126 [label="Function call arguments enter"]; + 127 [label="Function call arguments exit"]; } - 130 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 131 [label="Exit block"]; + 128 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 129 [label="Exit block"]; } - 132 [label="Exit function " style="filled" fillcolor=red]; + 130 [label="Exit function " style="filled" fillcolor=red]; } - 133 [label="Function call arguments exit"]; + 131 [label="Function call arguments exit"]; } - 134 [label="Postponed exit from lambda"]; - 135 [label="Postponed exit from lambda"]; - 136 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 132 [label="Postponed exit from lambda"]; + 133 [label="Postponed exit from lambda"]; + 134 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 135 [label="Access variable R|/p|"]; + 136 [label="Access variable #"]; 137 [label="Access variable R|/p|"]; - 138 [label="Smart cast: R|/p|"]; + 138 [label="Enter safe call"]; 139 [label="Access variable #"]; - 140 [label="Access variable R|/p|"]; - 141 [label="Smart cast: R|/p|"]; - 142 [label="Enter safe call"]; - 143 [label="Access variable #"]; - 144 [label="Exit safe call"]; - 145 [label="Exit block"]; + 140 [label="Exit safe call"]; + 141 [label="Exit block"]; } - 146 [label="Exit function test2" style="filled" fillcolor=red]; + 142 [label="Exit function test2" style="filled" fillcolor=red]; } + 107 -> {108}; + 108 -> {109}; 109 -> {110}; 110 -> {111}; 111 -> {112}; 112 -> {113}; 113 -> {114}; - 114 -> {115}; + 114 -> {115 122 131}; + 114 -> {132 133} [style=dotted]; + 114 -> {115 122} [style=dashed]; 115 -> {116}; - 116 -> {117 124 133}; - 116 -> {134 135} [style=dotted]; - 116 -> {117 124} [style=dashed]; + 116 -> {117}; 117 -> {118}; 118 -> {119}; 119 -> {120}; 120 -> {121}; - 121 -> {122}; + 121 -> {132}; 122 -> {123}; - 123 -> {134}; + 123 -> {124}; 124 -> {125}; 125 -> {126}; 126 -> {127}; 127 -> {128}; 128 -> {129}; 129 -> {130}; - 130 -> {131}; - 131 -> {132}; - 132 -> {135}; - 133 -> {136}; - 134 -> {136}; + 130 -> {133}; + 131 -> {134}; + 132 -> {134} [label="Postponed"]; + 133 -> {134} [label="Postponed"]; + 134 -> {135}; 135 -> {136}; 136 -> {137}; - 137 -> {138}; + 137 -> {138 140}; 138 -> {139}; 139 -> {140}; 140 -> {141}; - 141 -> {142 144}; - 142 -> {143}; - 143 -> {144}; - 144 -> {145}; - 145 -> {146}; + 141 -> {142}; subgraph cluster_38 { color=red - 147 [label="Enter function test3" style="filled" fillcolor=red]; + 143 [label="Enter function test3" style="filled" fillcolor=red]; subgraph cluster_39 { color=blue - 148 [label="Enter block"]; - 149 [label="Access variable R|/x|"]; - 150 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; - 151 [label="Access variable R|/p|"]; - 152 [label="Access variable #"]; + 144 [label="Enter block"]; + 145 [label="Access variable R|/x|"]; + 146 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; + 147 [label="Access variable R|/p|"]; + 148 [label="Access variable #"]; subgraph cluster_40 { color=blue - 153 [label="Function call arguments enter"]; - 154 [label="Postponed enter to lambda"]; + 149 [label="Function call arguments enter"]; + 150 [label="Postponed enter to lambda"]; subgraph cluster_41 { color=blue - 155 [label="Enter function " style="filled" fillcolor=red]; + 151 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_42 { color=blue - 156 [label="Enter block"]; - 157 [label="Const: String()"]; - 158 [label="Assignment: R|/p|"]; - 159 [label="Const: Int(123)"]; - 160 [label="Exit block"]; + 152 [label="Enter block"]; + 153 [label="Const: String()"]; + 154 [label="Assignment: R|/p|"]; + 155 [label="Const: Int(123)"]; + 156 [label="Exit block"]; } - 161 [label="Exit function " style="filled" fillcolor=red]; + 157 [label="Exit function " style="filled" fillcolor=red]; } subgraph cluster_43 { color=blue - 162 [label="Enter function " style="filled" fillcolor=red]; + 158 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_44 { color=blue - 163 [label="Enter block"]; - 164 [label="Const: Null(null)"]; - 165 [label="Assignment: R|/p|"]; + 159 [label="Enter block"]; + 160 [label="Const: Null(null)"]; + 161 [label="Assignment: R|/p|"]; subgraph cluster_45 { color=blue - 166 [label="Function call arguments enter"]; - 167 [label="Function call arguments exit"]; + 162 [label="Function call arguments enter"]; + 163 [label="Function call arguments exit"]; } - 168 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 169 [label="Exit block"]; + 164 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 165 [label="Exit block"]; } - 170 [label="Exit function " style="filled" fillcolor=red]; + 166 [label="Exit function " style="filled" fillcolor=red]; } - 171 [label="Function call arguments exit"]; + 167 [label="Function call arguments exit"]; } - 172 [label="Postponed exit from lambda"]; - 173 [label="Postponed exit from lambda"]; - 174 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; - 175 [label="Access variable R|/p|"]; - 176 [label="Smart cast: R|/p|"]; - 177 [label="Access variable R|kotlin/String.length#|"]; - 178 [label="Access variable R|/p|"]; - 179 [label="Smart cast: R|/p|"]; - 180 [label="Enter safe call"]; - 181 [label="Access variable R|kotlin/String.length|"]; - 182 [label="Exit safe call"]; - 183 [label="Exit block"]; + 168 [label="Postponed exit from lambda"]; + 169 [label="Postponed exit from lambda"]; + 170 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 171 [label="Access variable R|/p|"]; + 172 [label="Access variable #"]; + 173 [label="Access variable R|/p|"]; + 174 [label="Enter safe call"]; + 175 [label="Access variable #"]; + 176 [label="Exit safe call"]; + 177 [label="Exit block"]; } - 184 [label="Exit function test3" style="filled" fillcolor=red]; + 178 [label="Exit function test3" style="filled" fillcolor=red]; } + 143 -> {144}; + 144 -> {145}; + 145 -> {146}; + 146 -> {147}; 147 -> {148}; 148 -> {149}; 149 -> {150}; - 150 -> {151}; + 150 -> {151 158 167}; + 150 -> {168 169} [style=dotted]; + 150 -> {151 158} [style=dashed]; 151 -> {152}; 152 -> {153}; 153 -> {154}; - 154 -> {155 162 171}; - 154 -> {172 173} [style=dotted]; - 154 -> {155 162} [style=dashed]; + 154 -> {155}; 155 -> {156}; 156 -> {157}; - 157 -> {158}; + 157 -> {168}; 158 -> {159}; 159 -> {160}; 160 -> {161}; - 161 -> {172}; + 161 -> {162}; 162 -> {163}; 163 -> {164}; 164 -> {165}; 165 -> {166}; - 166 -> {167}; - 167 -> {168}; - 168 -> {169}; - 169 -> {170}; - 170 -> {173}; - 171 -> {174}; - 172 -> {174}; - 173 -> {174}; + 166 -> {169}; + 167 -> {170}; + 168 -> {170} [label="Postponed"]; + 169 -> {170} [label="Postponed"]; + 170 -> {171}; + 171 -> {172}; + 172 -> {173}; + 173 -> {174 176}; 174 -> {175}; 175 -> {176}; 176 -> {177}; 177 -> {178}; - 178 -> {179}; - 179 -> {180 182}; - 180 -> {181}; - 181 -> {182}; - 182 -> {183}; - 183 -> {184}; subgraph cluster_46 { color=red - 185 [label="Enter class I1" style="filled" fillcolor=red]; - 186 [label="Exit class I1" style="filled" fillcolor=red]; + 179 [label="Enter class I1" style="filled" fillcolor=red]; + 180 [label="Exit class I1" style="filled" fillcolor=red]; } - 185 -> {186} [color=green]; + 179 -> {180} [color=green]; subgraph cluster_47 { color=red - 187 [label="Enter class I2" style="filled" fillcolor=red]; - 188 [label="Exit class I2" style="filled" fillcolor=red]; + 181 [label="Enter class I2" style="filled" fillcolor=red]; + 182 [label="Exit class I2" style="filled" fillcolor=red]; } - 187 -> {188} [color=green]; + 181 -> {182} [color=green]; subgraph cluster_48 { color=red - 189 [label="Enter function test4" style="filled" fillcolor=red]; + 183 [label="Enter function test4" style="filled" fillcolor=red]; subgraph cluster_49 { color=blue - 190 [label="Enter block"]; - 191 [label="Access variable R|/x|"]; - 192 [label="Access variable #"]; - 193 [label="Access variable R|/x|"]; - 194 [label="Access variable #"]; + 184 [label="Enter block"]; + 185 [label="Access variable R|/x|"]; + 186 [label="Access variable #"]; + 187 [label="Access variable R|/x|"]; + 188 [label="Access variable #"]; subgraph cluster_50 { color=blue - 195 [label="Function call arguments enter"]; - 196 [label="Postponed enter to lambda"]; + 189 [label="Function call arguments enter"]; + 190 [label="Postponed enter to lambda"]; subgraph cluster_51 { color=blue - 197 [label="Enter function " style="filled" fillcolor=red]; + 191 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_52 { color=blue - 198 [label="Enter block"]; - 199 [label="Access variable R|/x|"]; - 200 [label="Type operator: (R|/x| as R|I2|)"]; - 201 [label="Access variable R|/x|"]; - 202 [label="Smart cast: R|/x|"]; - 203 [label="Access variable #"]; - 204 [label="Const: Int(123)"]; - 205 [label="Exit block"]; + 192 [label="Enter block"]; + 193 [label="Access variable R|/x|"]; + 194 [label="Type operator: (R|/x| as R|I2|)"]; + 195 [label="Access variable R|/x|"]; + 196 [label="Smart cast: R|/x|"]; + 197 [label="Access variable #"]; + 198 [label="Const: Int(123)"]; + 199 [label="Exit block"]; } - 206 [label="Exit function " style="filled" fillcolor=red]; + 200 [label="Exit function " style="filled" fillcolor=red]; } subgraph cluster_53 { color=blue - 207 [label="Enter function " style="filled" fillcolor=red]; + 201 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_54 { color=blue - 208 [label="Enter block"]; - 209 [label="Access variable R|/x|"]; - 210 [label="Type operator: (R|/x| as R|I1|)"]; - 211 [label="Access variable R|/x|"]; - 212 [label="Smart cast: R|/x|"]; - 213 [label="Access variable #"]; + 202 [label="Enter block"]; + 203 [label="Access variable R|/x|"]; + 204 [label="Type operator: (R|/x| as R|I1|)"]; + 205 [label="Access variable R|/x|"]; + 206 [label="Smart cast: R|/x|"]; + 207 [label="Access variable #"]; subgraph cluster_55 { color=blue - 214 [label="Function call arguments enter"]; - 215 [label="Function call arguments exit"]; + 208 [label="Function call arguments enter"]; + 209 [label="Function call arguments exit"]; } - 216 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 217 [label="Exit block"]; + 210 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 211 [label="Exit block"]; } - 218 [label="Exit function " style="filled" fillcolor=red]; + 212 [label="Exit function " style="filled" fillcolor=red]; } - 219 [label="Function call arguments exit"]; + 213 [label="Function call arguments exit"]; } - 220 [label="Postponed exit from lambda"]; - 221 [label="Postponed exit from lambda"]; - 222 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; - 223 [label="Access variable R|/x|"]; - 224 [label="Smart cast: R|/x|"]; - 225 [label="Access variable R|/I1.x|"]; - 226 [label="Access variable R|/x|"]; - 227 [label="Smart cast: R|/x|"]; - 228 [label="Access variable R|/I2.y|"]; - 229 [label="Exit block"]; + 214 [label="Postponed exit from lambda"]; + 215 [label="Postponed exit from lambda"]; + 216 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 217 [label="Access variable R|/x|"]; + 218 [label="Access variable #"]; + 219 [label="Access variable R|/x|"]; + 220 [label="Access variable #"]; + 221 [label="Exit block"]; } - 230 [label="Exit function test4" style="filled" fillcolor=red]; + 222 [label="Exit function test4" style="filled" fillcolor=red]; } + 183 -> {184}; + 184 -> {185}; + 185 -> {186}; + 186 -> {187}; + 187 -> {188}; + 188 -> {189}; 189 -> {190}; - 190 -> {191}; + 190 -> {191 201 213}; + 190 -> {214 215} [style=dotted]; + 190 -> {191 201} [style=dashed]; 191 -> {192}; 192 -> {193}; 193 -> {194}; 194 -> {195}; 195 -> {196}; - 196 -> {197 207 219}; - 196 -> {220 221} [style=dotted]; - 196 -> {197 207} [style=dashed]; + 196 -> {197}; 197 -> {198}; 198 -> {199}; 199 -> {200}; - 200 -> {201}; + 200 -> {214}; 201 -> {202}; 202 -> {203}; 203 -> {204}; 204 -> {205}; 205 -> {206}; - 206 -> {220}; + 206 -> {207}; 207 -> {208}; 208 -> {209}; 209 -> {210}; 210 -> {211}; 211 -> {212}; - 212 -> {213}; - 213 -> {214}; - 214 -> {215}; - 215 -> {216}; + 212 -> {215}; + 213 -> {216}; + 214 -> {216} [label="Postponed"]; + 215 -> {216} [label="Postponed"]; 216 -> {217}; 217 -> {218}; - 218 -> {221}; - 219 -> {222}; - 220 -> {222}; + 218 -> {219}; + 219 -> {220}; + 220 -> {221}; 221 -> {222}; - 222 -> {223}; + + subgraph cluster_56 { + color=red + 223 [label="Enter function test5" style="filled" fillcolor=red]; + subgraph cluster_57 { + color=blue + 224 [label="Enter block"]; + 225 [label="Access variable R|/x|"]; + 226 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; + 227 [label="Access variable R|/p|"]; + 228 [label="Access variable #"]; + subgraph cluster_58 { + color=blue + 229 [label="Function call arguments enter"]; + 230 [label="Postponed enter to lambda"]; + subgraph cluster_59 { + color=blue + 231 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_60 { + color=blue + 232 [label="Enter block"]; + 233 [label="Access variable R|/q|"]; + 234 [label="Assignment: R|/p|"]; + subgraph cluster_61 { + color=blue + 235 [label="Function call arguments enter"]; + 236 [label="Function call arguments exit"]; + } + 237 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; + 238 [label="Exit block"]; + } + 239 [label="Exit function " style="filled" fillcolor=red]; + } + subgraph cluster_62 { + color=blue + 240 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_63 { + color=blue + 241 [label="Enter block"]; + 242 [label="Access variable R|/p|"]; + 243 [label="Type operator: (R|/p| as R|kotlin/Int|)"]; + 244 [label="Const: Int(123)"]; + 245 [label="Exit block"]; + } + 246 [label="Exit function " style="filled" fillcolor=red]; + } + 247 [label="Function call arguments exit"]; + } + 248 [label="Postponed exit from lambda"]; + 249 [label="Postponed exit from lambda"]; + 250 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 251 [label="Access variable R|/p|"]; + 252 [label="Access variable #"]; + 253 [label="Access variable R|/p|"]; + 254 [label="Enter safe call"]; + 255 [label="Access variable #"]; + 256 [label="Exit safe call"]; + 257 [label="Exit block"]; + } + 258 [label="Exit function test5" style="filled" fillcolor=red]; + } 223 -> {224}; 224 -> {225}; 225 -> {226}; @@ -643,69 +695,9 @@ digraph flowFromTwoInplaceLambdas_kt { 227 -> {228}; 228 -> {229}; 229 -> {230}; - - subgraph cluster_56 { - color=red - 231 [label="Enter function test5" style="filled" fillcolor=red]; - subgraph cluster_57 { - color=blue - 232 [label="Enter block"]; - 233 [label="Access variable R|/x|"]; - 234 [label="Variable declaration: lvar p: R|kotlin/Any?|"]; - 235 [label="Access variable R|/p|"]; - 236 [label="Access variable #"]; - subgraph cluster_58 { - color=blue - 237 [label="Function call arguments enter"]; - 238 [label="Postponed enter to lambda"]; - subgraph cluster_59 { - color=blue - 239 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_60 { - color=blue - 240 [label="Enter block"]; - 241 [label="Access variable R|/q|"]; - 242 [label="Assignment: R|/p|"]; - subgraph cluster_61 { - color=blue - 243 [label="Function call arguments enter"]; - 244 [label="Function call arguments exit"]; - } - 245 [label="Function call: R|/n|()" style="filled" fillcolor=yellow]; - 246 [label="Exit block"]; - } - 247 [label="Exit function " style="filled" fillcolor=red]; - } - subgraph cluster_62 { - color=blue - 248 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_63 { - color=blue - 249 [label="Enter block"]; - 250 [label="Access variable R|/p|"]; - 251 [label="Type operator: (R|/p| as R|kotlin/Int|)"]; - 252 [label="Const: Int(123)"]; - 253 [label="Exit block"]; - } - 254 [label="Exit function " style="filled" fillcolor=red]; - } - 255 [label="Function call arguments exit"]; - } - 256 [label="Postponed exit from lambda"]; - 257 [label="Postponed exit from lambda"]; - 258 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; - 259 [label="Access variable R|/p|"]; - 260 [label="Smart cast: R|/p|"]; - 261 [label="Access variable R|kotlin/String.length#|"]; - 262 [label="Access variable R|/p|"]; - 263 [label="Smart cast: R|/p|"]; - 264 [label="Enter safe call"]; - 265 [label="Access variable R|kotlin/String.length|"]; - 266 [label="Exit safe call"]; - 267 [label="Exit block"]; - } - 268 [label="Exit function test5" style="filled" fillcolor=red]; - } + 230 -> {231 240 247}; + 230 -> {248 249} [style=dotted]; + 230 -> {231 240} [style=dashed]; 231 -> {232}; 232 -> {233}; 233 -> {234}; @@ -713,225 +705,213 @@ digraph flowFromTwoInplaceLambdas_kt { 235 -> {236}; 236 -> {237}; 237 -> {238}; - 238 -> {239 248 255}; - 238 -> {256 257} [style=dotted]; - 238 -> {239 248} [style=dashed]; - 239 -> {240}; + 238 -> {239}; + 239 -> {248}; 240 -> {241}; 241 -> {242}; 242 -> {243}; 243 -> {244}; 244 -> {245}; 245 -> {246}; - 246 -> {247}; - 247 -> {256}; - 248 -> {249}; - 249 -> {250}; + 246 -> {249}; + 247 -> {250}; + 248 -> {250} [label="Postponed"]; + 249 -> {250} [label="Postponed"]; 250 -> {251}; 251 -> {252}; 252 -> {253}; - 253 -> {254}; - 254 -> {257}; - 255 -> {258}; - 256 -> {258}; + 253 -> {254 256}; + 254 -> {255}; + 255 -> {256}; + 256 -> {257}; 257 -> {258}; - 258 -> {259}; + + subgraph cluster_64 { + color=red + 259 [label="Enter function test6" style="filled" fillcolor=red]; + subgraph cluster_65 { + color=blue + 260 [label="Enter block"]; + 261 [label="Variable declaration: lval x: R|kotlin/String|"]; + subgraph cluster_66 { + color=blue + 262 [label="Function call arguments enter"]; + 263 [label="Postponed enter to lambda"]; + subgraph cluster_67 { + color=blue + 264 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_68 { + color=blue + 265 [label="Enter block"]; + 266 [label="Access variable R|/x|"]; + 267 [label="Access variable R|kotlin/String.length|"]; + 268 [label="Exit block"]; + } + 269 [label="Exit function " style="filled" fillcolor=red]; + } + subgraph cluster_69 { + color=blue + 270 [label="Enter function " style="filled" fillcolor=red]; + subgraph cluster_70 { + color=blue + 271 [label="Enter block"]; + 272 [label="Const: String()"]; + 273 [label="Assignment: R|/x|"]; + 274 [label="Access variable R|/x|"]; + 275 [label="Access variable R|kotlin/String.length|"]; + 276 [label="Exit block"]; + } + 277 [label="Exit function " style="filled" fillcolor=red]; + } + 278 [label="Function call arguments exit"]; + } + 279 [label="Postponed exit from lambda"]; + 280 [label="Postponed exit from lambda"]; + 281 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 282 [label="Access variable R|/x|"]; + 283 [label="Access variable R|kotlin/String.length|"]; + 284 [label="Exit block"]; + } + 285 [label="Exit function test6" style="filled" fillcolor=red]; + } 259 -> {260}; 260 -> {261}; 261 -> {262}; 262 -> {263}; - 263 -> {264 266}; + 263 -> {264 270 278}; + 263 -> {279 280} [style=dotted]; + 263 -> {264 270} [style=dashed]; 264 -> {265}; 265 -> {266}; 266 -> {267}; 267 -> {268}; - - subgraph cluster_64 { - color=red - 269 [label="Enter function test6" style="filled" fillcolor=red]; - subgraph cluster_65 { - color=blue - 270 [label="Enter block"]; - 271 [label="Variable declaration: lval x: R|kotlin/String|"]; - subgraph cluster_66 { - color=blue - 272 [label="Function call arguments enter"]; - 273 [label="Postponed enter to lambda"]; - subgraph cluster_67 { - color=blue - 274 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_68 { - color=blue - 275 [label="Enter block"]; - 276 [label="Access variable R|/x|"]; - 277 [label="Access variable R|kotlin/String.length|"]; - 278 [label="Exit block"]; - } - 279 [label="Exit function " style="filled" fillcolor=red]; - } - subgraph cluster_69 { - color=blue - 280 [label="Enter function " style="filled" fillcolor=red]; - subgraph cluster_70 { - color=blue - 281 [label="Enter block"]; - 282 [label="Const: String()"]; - 283 [label="Assignment: R|/x|"]; - 284 [label="Access variable R|/x|"]; - 285 [label="Access variable R|kotlin/String.length|"]; - 286 [label="Exit block"]; - } - 287 [label="Exit function " style="filled" fillcolor=red]; - } - 288 [label="Function call arguments exit"]; - } - 289 [label="Postponed exit from lambda"]; - 290 [label="Postponed exit from lambda"]; - 291 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; - 292 [label="Access variable R|/x|"]; - 293 [label="Access variable R|kotlin/String.length|"]; - 294 [label="Exit block"]; - } - 295 [label="Exit function test6" style="filled" fillcolor=red]; - } - 269 -> {270}; + 268 -> {269}; + 269 -> {279}; 270 -> {271}; 271 -> {272}; 272 -> {273}; - 273 -> {274 280 288}; - 273 -> {289 290} [style=dotted]; - 273 -> {274 280} [style=dashed]; + 273 -> {274}; 274 -> {275}; 275 -> {276}; 276 -> {277}; - 277 -> {278}; - 278 -> {279}; - 279 -> {289}; - 280 -> {281}; + 277 -> {280}; + 278 -> {281}; + 279 -> {281} [label="Postponed"]; + 280 -> {281} [label="Postponed"]; 281 -> {282}; 282 -> {283}; 283 -> {284}; 284 -> {285}; - 285 -> {286}; - 286 -> {287}; - 287 -> {290}; - 288 -> {291}; - 289 -> {291}; - 290 -> {291}; - 291 -> {292}; - 292 -> {293}; - 293 -> {294}; - 294 -> {295}; subgraph cluster_71 { color=red - 296 [label="Enter function test7" style="filled" fillcolor=red]; + 286 [label="Enter function test7" style="filled" fillcolor=red]; subgraph cluster_72 { color=blue - 297 [label="Enter block"]; - 298 [label="Const: String()"]; - 299 [label="Variable declaration: lval x: R|kotlin/Any?|"]; - 300 [label="Variable declaration: lval y: R|kotlin/Any?|"]; + 287 [label="Enter block"]; + 288 [label="Const: String()"]; + 289 [label="Variable declaration: lval x: R|kotlin/Any?|"]; + 290 [label="Variable declaration: lval y: R|kotlin/Any?|"]; subgraph cluster_73 { color=blue - 301 [label="Function call arguments enter"]; - 302 [label="Postponed enter to lambda"]; + 291 [label="Function call arguments enter"]; + 292 [label="Postponed enter to lambda"]; subgraph cluster_74 { color=blue - 303 [label="Enter function " style="filled" fillcolor=red]; + 293 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_75 { color=blue - 304 [label="Enter block"]; - 305 [label="Jump: ^@run2 Unit"]; - 306 [label="Stub" style="filled" fillcolor=gray]; - 307 [label="Exit block" style="filled" fillcolor=gray]; + 294 [label="Enter block"]; + 295 [label="Jump: ^@run2 Unit"]; + 296 [label="Stub" style="filled" fillcolor=gray]; + 297 [label="Exit block" style="filled" fillcolor=gray]; } - 308 [label="Exit function " style="filled" fillcolor=red]; + 298 [label="Exit function " style="filled" fillcolor=red]; } subgraph cluster_76 { color=blue - 309 [label="Enter function " style="filled" fillcolor=red]; + 299 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_77 { color=blue - 310 [label="Enter block"]; - 311 [label="Access variable R|/x|"]; - 312 [label="Assignment: R|/y|"]; - 313 [label="Exit block"]; + 300 [label="Enter block"]; + 301 [label="Access variable R|/x|"]; + 302 [label="Assignment: R|/y|"]; + 303 [label="Exit block"]; } - 314 [label="Exit function " style="filled" fillcolor=red]; + 304 [label="Exit function " style="filled" fillcolor=red]; } - 315 [label="Function call arguments exit"]; + 305 [label="Function call arguments exit"]; } - 316 [label="Postponed exit from lambda"]; - 317 [label="Postponed exit from lambda"]; - 318 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; + 306 [label="Postponed exit from lambda"]; + 307 [label="Postponed exit from lambda"]; + 308 [label="Function call: R|/run2|(...)" style="filled" fillcolor=yellow]; subgraph cluster_78 { color=blue - 319 [label="Enter when"]; + 309 [label="Enter when"]; subgraph cluster_79 { color=blue - 320 [label="Enter when branch condition "]; - 321 [label="Access variable R|/y|"]; - 322 [label="Type operator: (R|/y| is R|kotlin/String|)"]; - 323 [label="Exit when branch condition"]; + 310 [label="Enter when branch condition "]; + 311 [label="Access variable R|/y|"]; + 312 [label="Type operator: (R|/y| is R|kotlin/String|)"]; + 313 [label="Exit when branch condition"]; } - 324 [label="Synthetic else branch"]; - 325 [label="Enter when branch result"]; + 314 [label="Synthetic else branch"]; + 315 [label="Enter when branch result"]; subgraph cluster_80 { color=blue - 326 [label="Enter block"]; - 327 [label="Access variable R|/x|"]; - 328 [label="Smart cast: R|/x|"]; - 329 [label="Access variable R|kotlin/String.length|"]; - 330 [label="Exit block"]; + 316 [label="Enter block"]; + 317 [label="Access variable R|/x|"]; + 318 [label="Smart cast: R|/x|"]; + 319 [label="Access variable R|kotlin/String.length|"]; + 320 [label="Exit block"]; } - 331 [label="Exit when branch result"]; - 332 [label="Exit when"]; + 321 [label="Exit when branch result"]; + 322 [label="Exit when"]; } - 333 [label="Exit block"]; + 323 [label="Exit block"]; } - 334 [label="Exit function test7" style="filled" fillcolor=red]; + 324 [label="Exit function test7" style="filled" fillcolor=red]; } - 296 -> {297}; - 297 -> {298}; - 298 -> {299}; + 286 -> {287}; + 287 -> {288}; + 288 -> {289}; + 289 -> {290}; + 290 -> {291}; + 291 -> {292}; + 292 -> {293 299 305}; + 292 -> {306 307} [style=dotted]; + 292 -> {293 299} [style=dashed]; + 293 -> {294}; + 294 -> {295}; + 295 -> {298}; + 295 -> {296} [style=dotted]; + 296 -> {297} [style=dotted]; + 297 -> {298} [style=dotted]; + 298 -> {306}; 299 -> {300}; 300 -> {301}; 301 -> {302}; - 302 -> {303 309 315}; - 302 -> {316 317} [style=dotted]; - 302 -> {303 309} [style=dashed]; + 302 -> {303}; 303 -> {304}; - 304 -> {305}; + 304 -> {307}; 305 -> {308}; - 305 -> {306} [style=dotted]; - 306 -> {307} [style=dotted]; - 307 -> {308} [style=dotted]; - 308 -> {316}; + 306 -> {308} [label="Postponed"]; + 307 -> {308} [label="Postponed"]; + 308 -> {309}; 309 -> {310}; 310 -> {311}; 311 -> {312}; 312 -> {313}; - 313 -> {314}; - 314 -> {317}; - 315 -> {318}; - 316 -> {318}; + 313 -> {314 315}; + 314 -> {322}; + 315 -> {316}; + 316 -> {317}; 317 -> {318}; 318 -> {319}; 319 -> {320}; 320 -> {321}; 321 -> {322}; 322 -> {323}; - 323 -> {324 325}; - 324 -> {332}; - 325 -> {326}; - 326 -> {327}; - 327 -> {328}; - 328 -> {329}; - 329 -> {330}; - 330 -> {331}; - 331 -> {332}; - 332 -> {333}; - 333 -> {334}; + 323 -> {324}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.fir.txt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.fir.txt index 2c291f3162d..9892c854ccf 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.fir.txt @@ -83,8 +83,8 @@ FILE: flowFromTwoInplaceLambdas.kt ^ Int(123) } ) - R|/p|.R|kotlin/String.length#| - R|/p|?.{ $subj$.R|kotlin/String.length| } + R|/p|.# + R|/p|?.{ $subj$.# } } public abstract interface I1 : R|kotlin/Any| { public abstract val x: R|kotlin/Int| @@ -110,8 +110,8 @@ FILE: flowFromTwoInplaceLambdas.kt ^ Int(123) } ) - R|/x|.R|/I1.x| - R|/x|.R|/I2.y| + R|/x|.# + R|/x|.# } public final fun test5(x: R|kotlin/Any?|, q: R|kotlin/String?|): R|kotlin/Unit| { lvar p: R|kotlin/Any?| = R|/x| @@ -125,8 +125,8 @@ FILE: flowFromTwoInplaceLambdas.kt ^ R|/n|() } ) - R|/p|.R|kotlin/String.length#| - R|/p|?.{ $subj$.R|kotlin/String.length| } + R|/p|.# + R|/p|?.{ $subj$.# } } public final fun test6(): R|kotlin/Unit| { lval x: R|kotlin/String| diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.kt b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.kt index b97a592d0a3..cf66788c929 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.kt +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/flowFromTwoInplaceLambdas.kt @@ -47,8 +47,8 @@ fun test3(x: Any?) { var p: Any? = x p.length // Bad run2({ p = null; n() }, { p = ""; 123 }) - p.length // Bad: p can be null - p?.length // OK: p is String | Nothing? = String? + p.length // Bad: p can be null + p?.length // Bad: KT-37838 -> OK: p is String | Nothing? = String? } interface I1 { val x: Int } @@ -61,16 +61,16 @@ fun test4(x: Any?) { { x as I1; x.y; n() }, // Bad: may or may not be called first { x as I2; x.x; 123 } // Bad: may or may not be called first ) - x.x // OK: x is I1 & I2 - x.y // OK: x is I1 & I2 + x.x // Bad: KT-37838 -> OK: x is I1 & I2 + x.y // Bad: KT-37838 -> OK: x is I1 & I2 } fun test5(x: Any?, q: String?) { var p: Any? = x p.length // Bad run2({ p as Int; 123 }, { p = q; n() }) - p.length // Bad: p is String? | (String? & Int) = String? - p?.length // OK: p is String? + p.length // Bad: p is String? | (String? & Int) = String? + p?.length // Bad: KT-37838 -> OK: p is String? } fun test6() { diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/initBlockAndInPlaceLambda.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/initBlockAndInPlaceLambda.dot index ba326aecc24..2482b221e76 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/initBlockAndInPlaceLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/initBlockAndInPlaceLambda.dot @@ -98,7 +98,7 @@ digraph initBlockAndInPlaceLambda_kt { 21 -> {22}; 22 -> {24}; 23 -> {25}; - 24 -> {25}; + 24 -> {25} [label="Postponed"]; 25 -> {26}; 26 -> {27}; 27 -> {28}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/inplaceLambdaInControlFlowExpressions.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/inplaceLambdaInControlFlowExpressions.dot index 409702f157f..9b9a129d1b5 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/inplaceLambdaInControlFlowExpressions.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/inplaceLambdaInControlFlowExpressions.dot @@ -128,7 +128,7 @@ digraph inplaceLambdaInControlFlowExpressions_kt { 34 -> {36}; 35 -> {37}; 36 -> {37} [color=green]; - 36 -> {40} [color=red]; + 36 -> {40} [color=red label="Postponed"]; 37 -> {38}; 38 -> {39}; 39 -> {40}; @@ -216,7 +216,7 @@ digraph inplaceLambdaInControlFlowExpressions_kt { 57 -> {59}; 58 -> {60}; 59 -> {60} [color=green]; - 59 -> {69} [color=red]; + 59 -> {69} [color=red label="Postponed"]; 60 -> {61}; 61 -> {62}; 62 -> {63 69}; @@ -281,7 +281,7 @@ digraph inplaceLambdaInControlFlowExpressions_kt { 83 -> {85}; 84 -> {86}; 85 -> {86} [color=green]; - 85 -> {87} [color=red]; + 85 -> {87} [color=red label="Postponed"]; 86 -> {87}; 87 -> {88}; 88 -> {89}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/jumps.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/jumps.dot index d70fa412179..a6468953611 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/jumps.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/jumps.dot @@ -478,8 +478,8 @@ digraph jumps_kt { 154 -> {155} [style=dotted]; 155 -> {157}; 156 -> {158}; - 157 -> {158}; 157 -> {149} [color=green style=dashed]; + 157 -> {158} [label="Postponed"]; 158 -> {159}; 159 -> {160}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaAsReturnOfLambda.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaAsReturnOfLambda.dot index 3a12c895308..daeb4d5961e 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaAsReturnOfLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaAsReturnOfLambda.dot @@ -77,7 +77,7 @@ digraph lambdaAsReturnOfLambda_kt { 16 -> {17} [style=dotted]; 17 -> {18} [style=dotted]; 19 -> {21}; - 20 -> {21}; + 20 -> {21} [label="Postponed"]; 21 -> {22}; 22 -> {23} [color=green]; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaReturningObject.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaReturningObject.dot index 74ba6f92abc..b811d609596 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaReturningObject.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdaReturningObject.dot @@ -132,7 +132,7 @@ digraph lambdaReturningObject_kt { 33 -> {34}; 35 -> {37}; 36 -> {37} [color=green]; - 36 -> {39} [color=red]; + 36 -> {39} [color=red label="Postponed"]; 37 -> {38}; 38 -> {39}; 39 -> {40}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdas.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdas.dot index 3abfb9a45cd..e517303099d 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/lambdas.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/lambdas.dot @@ -112,8 +112,8 @@ digraph lambdas_kt { 28 -> {29}; 29 -> {31}; 30 -> {32}; - 31 -> {32}; 31 -> {20} [color=green style=dashed]; + 31 -> {32} [label="Postponed"]; 32 -> {33}; 33 -> {34}; 34 -> {35}; @@ -276,8 +276,8 @@ digraph lambdas_kt { 83 -> {84} [style=dotted]; 84 -> {86} [style=dotted]; 85 -> {87}; - 86 -> {87}; 86 -> {77} [color=green style=dashed]; + 86 -> {87} [label="Postponed"]; 87 -> {88}; 88 -> {91}; 88 -> {89} [style=dotted]; @@ -334,8 +334,8 @@ digraph lambdas_kt { 101 -> {102} [style=dotted]; 102 -> {104} [style=dotted]; 103 -> {105}; - 104 -> {105}; 104 -> {95} [color=green style=dashed]; + 104 -> {105} [label="Postponed"]; 105 -> {106}; 106 -> {109}; 106 -> {107} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/localClassesWithImplicit.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/localClassesWithImplicit.dot index 220e286361e..1eda9078f48 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/localClassesWithImplicit.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/localClassesWithImplicit.dot @@ -447,8 +447,8 @@ digraph localClassesWithImplicit_kt { 58 -> {59}; 59 -> {61}; 60 -> {62}; - 61 -> {62}; 61 -> {47} [color=green style=dashed]; + 61 -> {62} [label="Postponed"]; 62 -> {63}; 63 -> {66}; 63 -> {64} [style=dotted]; @@ -490,8 +490,8 @@ digraph localClassesWithImplicit_kt { 99 -> {100}; 100 -> {102}; 101 -> {103}; - 102 -> {103}; 102 -> {70} [color=green style=dashed]; + 102 -> {103} [label="Postponed"]; 103 -> {104}; 104 -> {107}; 104 -> {105} [style=dotted]; @@ -531,8 +531,8 @@ digraph localClassesWithImplicit_kt { 134 -> {135}; 135 -> {137}; 136 -> {138}; - 137 -> {138}; 137 -> {123} [color=green style=dashed]; + 137 -> {138} [label="Postponed"]; 138 -> {139}; 139 -> {142}; 139 -> {140} [style=dotted]; @@ -574,8 +574,8 @@ digraph localClassesWithImplicit_kt { 175 -> {176}; 176 -> {178}; 177 -> {179}; - 178 -> {179}; 178 -> {146} [color=green style=dashed]; + 178 -> {179} [label="Postponed"]; 179 -> {180}; 180 -> {183}; 180 -> {181} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInConstructor.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInConstructor.dot index 2b96608af18..e6459390979 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInConstructor.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInConstructor.dot @@ -100,7 +100,7 @@ digraph postponedLambdaInConstructor_kt { 24 -> {26}; 25 -> {27}; 26 -> {27} [color=green]; - 26 -> {28} [color=red]; + 26 -> {28} [color=red label="Postponed"]; 27 -> {28}; 28 -> {29}; 29 -> {30} [color=green]; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInReturn.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInReturn.dot index 868b021b9e4..8934336a667 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInReturn.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdaInReturn.dot @@ -231,7 +231,7 @@ digraph postponedLambdaInReturn_kt { 67 -> {68} [style=dotted]; 68 -> {70}; 69 -> {71}; - 70 -> {71}; + 70 -> {71} [label="Postponed"]; 71 -> {72}; 72 -> {73}; 73 -> {74}; @@ -402,7 +402,7 @@ digraph postponedLambdaInReturn_kt { 121 -> {122} [style=dotted]; 122 -> {124}; 123 -> {125}; - 124 -> {125}; + 124 -> {125} [label="Postponed"]; 125 -> {126}; 126 -> {127}; 127 -> {128}; @@ -565,7 +565,7 @@ digraph postponedLambdaInReturn_kt { 176 -> {177} [style=dotted]; 177 -> {179}; 178 -> {180}; - 179 -> {180}; + 179 -> {180} [label="Postponed"]; 180 -> {181}; 181 -> {182}; 182 -> {183}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdas.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdas.dot index 1ebbb656ede..a3f2222dbb8 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdas.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/postponedLambdas.dot @@ -67,7 +67,7 @@ digraph postponedLambdas_kt { 14 -> {15}; 15 -> {16}; 17 -> {19}; - 18 -> {19}; + 18 -> {19} [label="Postponed"]; 19 -> {20}; 20 -> {21}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/propertiesAndInitBlocks.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/propertiesAndInitBlocks.dot index e4db48e914a..37f0e17e4eb 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/propertiesAndInitBlocks.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/propertiesAndInitBlocks.dot @@ -212,8 +212,8 @@ digraph propertiesAndInitBlocks_kt { 48 -> {49} [style=dotted]; 49 -> {50} [style=dotted]; 51 -> {53}; - 52 -> {53}; 52 -> {9} [color=green style=dashed]; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55} [color=green]; 55 -> {56}; diff --git a/compiler/fir/analysis-tests/testData/resolve/cfg/returnValuesFromLambda.dot b/compiler/fir/analysis-tests/testData/resolve/cfg/returnValuesFromLambda.dot index 69c4e9ef0a7..ce8235aaa5d 100644 --- a/compiler/fir/analysis-tests/testData/resolve/cfg/returnValuesFromLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolve/cfg/returnValuesFromLambda.dot @@ -145,7 +145,7 @@ digraph returnValuesFromLambda_kt { 38 -> {39}; 39 -> {41}; 40 -> {42}; - 41 -> {42}; + 41 -> {42} [label="Postponed"]; 42 -> {43}; 43 -> {44}; 44 -> {45}; @@ -204,7 +204,7 @@ digraph returnValuesFromLambda_kt { 57 -> {58} [style=dotted]; 58 -> {60}; 59 -> {61}; - 60 -> {61}; + 60 -> {61} [label="Postponed"]; 61 -> {62}; 62 -> {63}; 63 -> {64}; @@ -255,7 +255,7 @@ digraph returnValuesFromLambda_kt { 73 -> {74} [style=dotted]; 74 -> {76} [style=dotted]; 75 -> {77} [style=dotted]; - 76 -> {77} [style=dotted]; + 76 -> {77} [style=dotted label="Postponed"]; 77 -> {78} [style=dotted]; 78 -> {79} [style=dotted]; 79 -> {80} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolve/classCallInLambda.dot b/compiler/fir/analysis-tests/testData/resolve/classCallInLambda.dot index c8062d53f71..4afd3a34c31 100644 --- a/compiler/fir/analysis-tests/testData/resolve/classCallInLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolve/classCallInLambda.dot @@ -60,7 +60,7 @@ digraph classCallInLambda_kt { 11 -> {12}; 12 -> {14}; 13 -> {15}; - 14 -> {15}; + 14 -> {15} [label="Postponed"]; 15 -> {16}; 16 -> {19}; 16 -> {17} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/controlStructures/returns.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/controlStructures/returns.dot index 323b9032295..afe2d9f5d3a 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/controlStructures/returns.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/controlStructures/returns.dot @@ -601,7 +601,7 @@ digraph returns_kt { 205 -> {206}; 206 -> {207}; 208 -> {210}; - 209 -> {210}; + 209 -> {210} [label="Postponed"]; 210 -> {211}; 211 -> {212}; diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/incorrectSmartcastToNothing.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/incorrectSmartcastToNothing.dot index 365e4ac3207..b8c657d6ca1 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/incorrectSmartcastToNothing.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/incorrectSmartcastToNothing.dot @@ -187,7 +187,7 @@ digraph incorrectSmartcastToNothing_kt { 57 -> {58 60}; 58 -> {59}; 59 -> {61}; - 60 -> {61} [color=red]; + 60 -> {61} [color=red label="Postponed"]; 61 -> {62}; 62 -> {63}; 63 -> {64}; diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.dot index 8b6de3681c8..64188ebf9de 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.dot @@ -118,7 +118,7 @@ digraph inPlaceLambdas_kt { 29 -> {30}; 30 -> {32}; 31 -> {33}; - 32 -> {33}; + 32 -> {33} [label="Postponed"]; 33 -> {34}; 34 -> {35}; 35 -> {36}; @@ -155,13 +155,12 @@ digraph inPlaceLambdas_kt { color=blue 52 [label="Function call arguments enter"]; 53 [label="Access variable R|/x|"]; - 54 [label="Smart cast: R|/x|"]; - 55 [label="Function call arguments exit"]; + 54 [label="Function call arguments exit"]; } - 56 [label="Function call: R|/x|.R|/B.bar|()" style="filled" fillcolor=yellow]; - 57 [label="Exit block"]; + 55 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 56 [label="Exit block"]; } - 58 [label="Exit function test_2" style="filled" fillcolor=red]; + 57 [label="Exit function test_2" style="filled" fillcolor=red]; } 39 -> {40}; 40 -> {41}; @@ -176,96 +175,96 @@ digraph inPlaceLambdas_kt { 47 -> {48}; 48 -> {50}; 49 -> {51}; - 50 -> {51}; + 50 -> {51} [label="Postponed"]; 51 -> {52}; 52 -> {53}; 53 -> {54}; 54 -> {55}; 55 -> {56}; 56 -> {57}; - 57 -> {58}; subgraph cluster_20 { color=red - 59 [label="Enter function test_3" style="filled" fillcolor=red]; + 58 [label="Enter function test_3" style="filled" fillcolor=red]; subgraph cluster_21 { color=blue - 60 [label="Enter block"]; + 59 [label="Enter block"]; subgraph cluster_22 { color=blue - 61 [label="Enter when"]; + 60 [label="Enter when"]; subgraph cluster_23 { color=blue - 62 [label="Enter when branch condition "]; - 63 [label="Access variable R|/x|"]; - 64 [label="Type operator: (R|/x| is R|A|)"]; - 65 [label="Exit when branch condition"]; + 61 [label="Enter when branch condition "]; + 62 [label="Access variable R|/x|"]; + 63 [label="Type operator: (R|/x| is R|A|)"]; + 64 [label="Exit when branch condition"]; } - 66 [label="Synthetic else branch"]; - 67 [label="Enter when branch result"]; + 65 [label="Synthetic else branch"]; + 66 [label="Enter when branch result"]; subgraph cluster_24 { color=blue - 68 [label="Enter block"]; + 67 [label="Enter block"]; subgraph cluster_25 { color=blue - 69 [label="Function call arguments enter"]; - 70 [label="Postponed enter to lambda"]; + 68 [label="Function call arguments enter"]; + 69 [label="Postponed enter to lambda"]; subgraph cluster_26 { color=blue - 71 [label="Enter function " style="filled" fillcolor=red]; + 70 [label="Enter function " style="filled" fillcolor=red]; subgraph cluster_27 { color=blue - 72 [label="Enter block"]; + 71 [label="Enter block"]; subgraph cluster_28 { color=blue - 73 [label="Function call arguments enter"]; - 74 [label="Access variable R|/x|"]; - 75 [label="Smart cast: R|/x|"]; - 76 [label="Function call arguments exit"]; + 72 [label="Function call arguments enter"]; + 73 [label="Access variable R|/x|"]; + 74 [label="Smart cast: R|/x|"]; + 75 [label="Function call arguments exit"]; } - 77 [label="Function call: R|/x|.R|/A.foo|()" style="filled" fillcolor=yellow]; - 78 [label="Access variable R|/x|"]; - 79 [label="Smart cast: R|/x|"]; - 80 [label="Type operator: (R|/x| as R|B|)"]; - 81 [label="Exit block"]; + 76 [label="Function call: R|/x|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 77 [label="Access variable R|/x|"]; + 78 [label="Smart cast: R|/x|"]; + 79 [label="Type operator: (R|/x| as R|B|)"]; + 80 [label="Exit block"]; } - 82 [label="Exit function " style="filled" fillcolor=red]; + 81 [label="Exit function " style="filled" fillcolor=red]; } - 83 [label="Function call arguments exit"]; + 82 [label="Function call arguments exit"]; } - 84 [label="Postponed exit from lambda"]; - 85 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; + 83 [label="Postponed exit from lambda"]; + 84 [label="Function call: R|kotlin/run|(...)" style="filled" fillcolor=yellow]; subgraph cluster_29 { color=blue - 86 [label="Function call arguments enter"]; - 87 [label="Access variable R|/x|"]; - 88 [label="Smart cast: R|/x|"]; - 89 [label="Function call arguments exit"]; + 85 [label="Function call arguments enter"]; + 86 [label="Access variable R|/x|"]; + 87 [label="Smart cast: R|/x|"]; + 88 [label="Function call arguments exit"]; } - 90 [label="Function call: R|/x|.R|/B.bar|()" style="filled" fillcolor=yellow]; - 91 [label="Exit block"]; + 89 [label="Function call: R|/x|.#()" style="filled" fillcolor=yellow]; + 90 [label="Exit block"]; } - 92 [label="Exit when branch result"]; - 93 [label="Exit when"]; + 91 [label="Exit when branch result"]; + 92 [label="Exit when"]; } - 94 [label="Exit block"]; + 93 [label="Exit block"]; } - 95 [label="Exit function test_3" style="filled" fillcolor=red]; + 94 [label="Exit function test_3" style="filled" fillcolor=red]; } + 58 -> {59}; 59 -> {60}; 60 -> {61}; 61 -> {62}; 62 -> {63}; 63 -> {64}; - 64 -> {65}; - 65 -> {66 67}; - 66 -> {93}; + 64 -> {65 66}; + 65 -> {92}; + 66 -> {67}; 67 -> {68}; 68 -> {69}; - 69 -> {70}; - 70 -> {71 83}; - 70 -> {84} [style=dotted]; - 70 -> {71} [style=dashed]; + 69 -> {70 82}; + 69 -> {83} [style=dotted]; + 69 -> {70} [style=dashed]; + 70 -> {71}; 71 -> {72}; 72 -> {73}; 73 -> {74}; @@ -276,9 +275,9 @@ digraph inPlaceLambdas_kt { 78 -> {79}; 79 -> {80}; 80 -> {81}; - 81 -> {82}; + 81 -> {83}; 82 -> {84}; - 83 -> {85}; + 83 -> {84} [label="Postponed"]; 84 -> {85}; 85 -> {86}; 86 -> {87}; @@ -289,6 +288,5 @@ digraph inPlaceLambdas_kt { 91 -> {92}; 92 -> {93}; 93 -> {94}; - 94 -> {95}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.fir.txt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.fir.txt index 6efdacbcf0d..05d193bf18f 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.fir.txt @@ -23,7 +23,7 @@ FILE: inPlaceLambdas.kt ^ (R|/x| as R|B|) } ) - R|/x|.R|/B.bar|() + R|/x|.#() } public final fun test_3(x: R|kotlin/Any?|): R|kotlin/Unit| { when () { @@ -33,7 +33,7 @@ FILE: inPlaceLambdas.kt ^ (R|/x| as R|B|) } ) - R|/x|.R|/B.bar|() + R|/x|.#() } } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.kt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.kt index abc7a141b50..7ac874f5e1a 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.kt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/inPlaceLambdas.kt @@ -19,7 +19,7 @@ fun test_2(x: Any?) { run { x as B } - x.bar() + x.bar() } fun test_3(x: Any?) { @@ -28,6 +28,6 @@ fun test_3(x: Any?) { x.foo() x as B } - x.bar() + x.bar() } } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/lambdaInWhenBranch.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/lambdaInWhenBranch.dot index 9904f0f33b4..49b43ec5573 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/lambdaInWhenBranch.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/lambdas/lambdaInWhenBranch.dot @@ -245,7 +245,7 @@ digraph lambdaInWhenBranch_kt { 57 -> {59}; 58 -> {60}; 59 -> {60} [color=green]; - 59 -> {63} [color=red]; + 59 -> {63} [color=red label="Postponed"]; 60 -> {61}; 61 -> {62}; 62 -> {63}; diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.dot index e3b7dfe2540..e139e5b7f3f 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.dot @@ -401,49 +401,48 @@ digraph implicitReceivers_kt { color=blue 140 [label="Function call arguments enter"]; 141 [label="Access variable this@R|special/anonymous|"]; - 142 [label="Smart cast: this@R|special/anonymous|"]; - 143 [label="Function call arguments exit"]; + 142 [label="Function call arguments exit"]; } - 144 [label="Function call: this@R|special/anonymous|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 143 [label="Function call: this@R|special/anonymous|.#()" style="filled" fillcolor=yellow]; subgraph cluster_51 { color=blue - 145 [label="Function call arguments enter"]; - 146 [label="Function call arguments exit"]; + 144 [label="Function call arguments enter"]; + 145 [label="Function call arguments exit"]; } - 147 [label="Function call: this@R|special/anonymous|.R|/A.foo|()" style="filled" fillcolor=yellow]; - 148 [label="Exit block"]; + 146 [label="Function call: #()" style="filled" fillcolor=yellow]; + 147 [label="Exit block"]; } - 149 [label="Exit function " style="filled" fillcolor=red]; + 148 [label="Exit function " style="filled" fillcolor=red]; } - 150 [label="Function call arguments exit"]; + 149 [label="Function call arguments exit"]; } - 151 [label="Postponed exit from lambda"]; - 152 [label="Function call: R|kotlin/with|(...)" style="filled" fillcolor=yellow]; - 153 [label="Exit block"]; + 150 [label="Postponed exit from lambda"]; + 151 [label="Function call: R|kotlin/with#|>(...)" style="filled" fillcolor=yellow]; + 152 [label="Exit block"]; } - 154 [label="Exit function " style="filled" fillcolor=red]; + 153 [label="Exit function " style="filled" fillcolor=red]; } - 155 [label="Function call arguments exit"]; + 154 [label="Function call arguments exit"]; } - 156 [label="Postponed exit from lambda"]; - 157 [label="Function call: R|kotlin/with|(...)" style="filled" fillcolor=yellow]; - 158 [label="Exit block"]; + 155 [label="Postponed exit from lambda"]; + 156 [label="Function call: R|kotlin/with#|>(...)" style="filled" fillcolor=yellow]; + 157 [label="Exit block"]; } - 159 [label="Exit function test_3" style="filled" fillcolor=red]; + 158 [label="Exit function test_3" style="filled" fillcolor=red]; } 108 -> {109}; 109 -> {110}; 110 -> {111}; 111 -> {112}; - 112 -> {113 155}; - 112 -> {156} [style=dotted]; + 112 -> {113 154}; + 112 -> {155} [style=dotted]; 112 -> {113} [style=dashed]; 113 -> {114}; 114 -> {115}; 115 -> {116}; 116 -> {117}; - 117 -> {118 150}; - 117 -> {151} [style=dotted]; + 117 -> {118 149}; + 117 -> {150} [style=dotted]; 117 -> {118} [style=dashed]; 118 -> {119}; 119 -> {120}; @@ -467,7 +466,7 @@ digraph implicitReceivers_kt { 135 -> {136}; 136 -> {138}; 137 -> {139}; - 138 -> {139}; + 138 -> {139} [label="Postponed"]; 139 -> {140}; 140 -> {141}; 141 -> {142}; @@ -477,195 +476,195 @@ digraph implicitReceivers_kt { 145 -> {146}; 146 -> {147}; 147 -> {148}; - 148 -> {149}; + 148 -> {150}; 149 -> {151}; - 150 -> {152}; - 151 -> {152} [color=green]; - 151 -> {157} [color=red]; + 150 -> {151} [color=green]; + 150 -> {156} [color=red label="Postponed"]; + 151 -> {152}; 152 -> {153}; - 153 -> {154}; + 153 -> {155}; 154 -> {156}; - 155 -> {157}; + 155 -> {156} [label="Postponed"]; 156 -> {157}; 157 -> {158}; - 158 -> {159}; subgraph cluster_52 { color=red - 160 [label="Enter function test_4" style="filled" fillcolor=red]; + 159 [label="Enter function test_4" style="filled" fillcolor=red]; subgraph cluster_53 { color=blue - 161 [label="Enter block"]; + 160 [label="Enter block"]; subgraph cluster_54 { color=blue - 162 [label="Enter when"]; + 161 [label="Enter when"]; subgraph cluster_55 { color=blue - 163 [label="Enter when branch condition "]; - 164 [label="Access variable this@R|/test_4|"]; - 165 [label="Type operator: (this@R|/test_4| !is R|A|)"]; - 166 [label="Exit when branch condition"]; + 162 [label="Enter when branch condition "]; + 163 [label="Access variable this@R|/test_4|"]; + 164 [label="Type operator: (this@R|/test_4| !is R|A|)"]; + 165 [label="Exit when branch condition"]; } subgraph cluster_56 { color=blue - 167 [label="Enter when branch condition "]; - 168 [label="Access variable this@R|/test_4|"]; - 169 [label="Smart cast: this@R|/test_4|"]; - 170 [label="Type operator: (this@R|/test_4| !is R|B|)"]; - 171 [label="Exit when branch condition"]; + 166 [label="Enter when branch condition "]; + 167 [label="Access variable this@R|/test_4|"]; + 168 [label="Smart cast: this@R|/test_4|"]; + 169 [label="Type operator: (this@R|/test_4| !is R|B|)"]; + 170 [label="Exit when branch condition"]; } subgraph cluster_57 { color=blue - 172 [label="Enter when branch condition else"]; - 173 [label="Exit when branch condition"]; + 171 [label="Enter when branch condition else"]; + 172 [label="Exit when branch condition"]; } - 174 [label="Enter when branch result"]; + 173 [label="Enter when branch result"]; subgraph cluster_58 { color=blue - 175 [label="Enter block"]; + 174 [label="Enter block"]; subgraph cluster_59 { color=blue - 176 [label="Function call arguments enter"]; - 177 [label="Access variable this@R|/test_4|"]; - 178 [label="Smart cast: this@R|/test_4|"]; - 179 [label="Function call arguments exit"]; + 175 [label="Function call arguments enter"]; + 176 [label="Access variable this@R|/test_4|"]; + 177 [label="Smart cast: this@R|/test_4|"]; + 178 [label="Function call arguments exit"]; } - 180 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 179 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; subgraph cluster_60 { color=blue - 181 [label="Function call arguments enter"]; - 182 [label="Function call arguments exit"]; + 180 [label="Function call arguments enter"]; + 181 [label="Function call arguments exit"]; } - 183 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 182 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; subgraph cluster_61 { color=blue - 184 [label="Function call arguments enter"]; - 185 [label="Access variable this@R|/test_4|"]; - 186 [label="Smart cast: this@R|/test_4|"]; - 187 [label="Function call arguments exit"]; + 183 [label="Function call arguments enter"]; + 184 [label="Access variable this@R|/test_4|"]; + 185 [label="Smart cast: this@R|/test_4|"]; + 186 [label="Function call arguments exit"]; } - 188 [label="Function call: this@R|/test_4|.R|/B.bar|()" style="filled" fillcolor=yellow]; + 187 [label="Function call: this@R|/test_4|.R|/B.bar|()" style="filled" fillcolor=yellow]; subgraph cluster_62 { color=blue - 189 [label="Function call arguments enter"]; - 190 [label="Function call arguments exit"]; + 188 [label="Function call arguments enter"]; + 189 [label="Function call arguments exit"]; } - 191 [label="Function call: this@R|/test_4|.R|/B.bar|()" style="filled" fillcolor=yellow]; - 192 [label="Exit block"]; + 190 [label="Function call: this@R|/test_4|.R|/B.bar|()" style="filled" fillcolor=yellow]; + 191 [label="Exit block"]; } - 193 [label="Exit when branch result"]; - 194 [label="Enter when branch result"]; + 192 [label="Exit when branch result"]; + 193 [label="Enter when branch result"]; subgraph cluster_63 { color=blue - 195 [label="Enter block"]; + 194 [label="Enter block"]; subgraph cluster_64 { color=blue - 196 [label="Function call arguments enter"]; - 197 [label="Access variable this@R|/test_4|"]; - 198 [label="Smart cast: this@R|/test_4|"]; - 199 [label="Function call arguments exit"]; + 195 [label="Function call arguments enter"]; + 196 [label="Access variable this@R|/test_4|"]; + 197 [label="Smart cast: this@R|/test_4|"]; + 198 [label="Function call arguments exit"]; } - 200 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; + 199 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; subgraph cluster_65 { color=blue - 201 [label="Function call arguments enter"]; - 202 [label="Function call arguments exit"]; + 200 [label="Function call arguments enter"]; + 201 [label="Function call arguments exit"]; } - 203 [label="Function call: #()" style="filled" fillcolor=yellow]; + 202 [label="Function call: #()" style="filled" fillcolor=yellow]; subgraph cluster_66 { color=blue - 204 [label="Function call arguments enter"]; - 205 [label="Access variable this@R|/test_4|"]; - 206 [label="Smart cast: this@R|/test_4|"]; - 207 [label="Function call arguments exit"]; + 203 [label="Function call arguments enter"]; + 204 [label="Access variable this@R|/test_4|"]; + 205 [label="Smart cast: this@R|/test_4|"]; + 206 [label="Function call arguments exit"]; } - 208 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 207 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; subgraph cluster_67 { color=blue - 209 [label="Function call arguments enter"]; - 210 [label="Function call arguments exit"]; + 208 [label="Function call arguments enter"]; + 209 [label="Function call arguments exit"]; } - 211 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; - 212 [label="Exit block"]; + 210 [label="Function call: this@R|/test_4|.R|/A.foo|()" style="filled" fillcolor=yellow]; + 211 [label="Exit block"]; } - 213 [label="Exit when branch result"]; - 214 [label="Enter when branch result"]; + 212 [label="Exit when branch result"]; + 213 [label="Enter when branch result"]; subgraph cluster_68 { color=blue - 215 [label="Enter block"]; + 214 [label="Enter block"]; subgraph cluster_69 { color=blue - 216 [label="Function call arguments enter"]; - 217 [label="Access variable this@R|/test_4|"]; - 218 [label="Function call arguments exit"]; + 215 [label="Function call arguments enter"]; + 216 [label="Access variable this@R|/test_4|"]; + 217 [label="Function call arguments exit"]; } - 219 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; + 218 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; subgraph cluster_70 { color=blue - 220 [label="Function call arguments enter"]; - 221 [label="Function call arguments exit"]; + 219 [label="Function call arguments enter"]; + 220 [label="Function call arguments exit"]; } - 222 [label="Function call: #()" style="filled" fillcolor=yellow]; + 221 [label="Function call: #()" style="filled" fillcolor=yellow]; subgraph cluster_71 { color=blue - 223 [label="Function call arguments enter"]; - 224 [label="Access variable this@R|/test_4|"]; - 225 [label="Function call arguments exit"]; + 222 [label="Function call arguments enter"]; + 223 [label="Access variable this@R|/test_4|"]; + 224 [label="Function call arguments exit"]; } - 226 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; + 225 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; subgraph cluster_72 { color=blue - 227 [label="Function call arguments enter"]; - 228 [label="Function call arguments exit"]; + 226 [label="Function call arguments enter"]; + 227 [label="Function call arguments exit"]; } - 229 [label="Function call: #()" style="filled" fillcolor=yellow]; - 230 [label="Exit block"]; + 228 [label="Function call: #()" style="filled" fillcolor=yellow]; + 229 [label="Exit block"]; } - 231 [label="Exit when branch result"]; - 232 [label="Exit when"]; + 230 [label="Exit when branch result"]; + 231 [label="Exit when"]; } subgraph cluster_73 { color=blue - 233 [label="Function call arguments enter"]; - 234 [label="Access variable this@R|/test_4|"]; - 235 [label="Function call arguments exit"]; + 232 [label="Function call arguments enter"]; + 233 [label="Access variable this@R|/test_4|"]; + 234 [label="Function call arguments exit"]; } - 236 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; + 235 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; subgraph cluster_74 { color=blue - 237 [label="Function call arguments enter"]; - 238 [label="Function call arguments exit"]; + 236 [label="Function call arguments enter"]; + 237 [label="Function call arguments exit"]; } - 239 [label="Function call: #()" style="filled" fillcolor=yellow]; + 238 [label="Function call: #()" style="filled" fillcolor=yellow]; subgraph cluster_75 { color=blue - 240 [label="Function call arguments enter"]; - 241 [label="Access variable this@R|/test_4|"]; - 242 [label="Function call arguments exit"]; + 239 [label="Function call arguments enter"]; + 240 [label="Access variable this@R|/test_4|"]; + 241 [label="Function call arguments exit"]; } - 243 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; + 242 [label="Function call: this@R|/test_4|.#()" style="filled" fillcolor=yellow]; subgraph cluster_76 { color=blue - 244 [label="Function call arguments enter"]; - 245 [label="Function call arguments exit"]; + 243 [label="Function call arguments enter"]; + 244 [label="Function call arguments exit"]; } - 246 [label="Function call: #()" style="filled" fillcolor=yellow]; - 247 [label="Exit block"]; + 245 [label="Function call: #()" style="filled" fillcolor=yellow]; + 246 [label="Exit block"]; } - 248 [label="Exit function test_4" style="filled" fillcolor=red]; + 247 [label="Exit function test_4" style="filled" fillcolor=red]; } + 159 -> {160}; 160 -> {161}; 161 -> {162}; 162 -> {163}; 163 -> {164}; 164 -> {165}; - 165 -> {166}; - 166 -> {167 214}; + 165 -> {166 213}; + 166 -> {167}; 167 -> {168}; 168 -> {169}; 169 -> {170}; - 170 -> {171}; - 171 -> {172 194}; + 170 -> {171 193}; + 171 -> {172}; 172 -> {173}; 173 -> {174}; 174 -> {175}; @@ -686,8 +685,8 @@ digraph implicitReceivers_kt { 189 -> {190}; 190 -> {191}; 191 -> {192}; - 192 -> {193}; - 193 -> {232}; + 192 -> {231}; + 193 -> {194}; 194 -> {195}; 195 -> {196}; 196 -> {197}; @@ -706,8 +705,8 @@ digraph implicitReceivers_kt { 209 -> {210}; 210 -> {211}; 211 -> {212}; - 212 -> {213}; - 213 -> {232}; + 212 -> {231}; + 213 -> {214}; 214 -> {215}; 215 -> {216}; 216 -> {217}; @@ -741,63 +740,62 @@ digraph implicitReceivers_kt { 244 -> {245}; 245 -> {246}; 246 -> {247}; - 247 -> {248}; subgraph cluster_77 { color=red - 249 [label="Enter function test_5" style="filled" fillcolor=red]; + 248 [label="Enter function test_5" style="filled" fillcolor=red]; subgraph cluster_78 { color=blue - 250 [label="Enter block"]; + 249 [label="Enter block"]; subgraph cluster_79 { color=blue - 251 [label="Enter when"]; + 250 [label="Enter when"]; subgraph cluster_80 { color=blue - 252 [label="Enter when branch condition "]; - 253 [label="Access variable this@R|/test_5|"]; - 254 [label="Type operator: (this@R|/test_5| is R|kotlin/collections/List<*>|)"]; - 255 [label="Exit when branch condition"]; + 251 [label="Enter when branch condition "]; + 252 [label="Access variable this@R|/test_5|"]; + 253 [label="Type operator: (this@R|/test_5| is R|kotlin/collections/List<*>|)"]; + 254 [label="Exit when branch condition"]; } subgraph cluster_81 { color=blue - 256 [label="Enter when branch condition "]; - 257 [label="Access variable this@R|/test_5|"]; - 258 [label="Type operator: (this@R|/test_5| is R|kotlin/String|)"]; - 259 [label="Exit when branch condition"]; + 255 [label="Enter when branch condition "]; + 256 [label="Access variable this@R|/test_5|"]; + 257 [label="Type operator: (this@R|/test_5| is R|kotlin/String|)"]; + 258 [label="Exit when branch condition"]; } subgraph cluster_82 { color=blue - 260 [label="Enter when branch condition else"]; - 261 [label="Exit when branch condition"]; + 259 [label="Enter when branch condition else"]; + 260 [label="Exit when branch condition"]; } - 262 [label="Enter when branch result"]; + 261 [label="Enter when branch result"]; subgraph cluster_83 { color=blue - 263 [label="Enter block"]; - 264 [label="Const: Int(0)"]; - 265 [label="Exit block"]; + 262 [label="Enter block"]; + 263 [label="Const: Int(0)"]; + 264 [label="Exit block"]; } - 266 [label="Exit when branch result"]; - 267 [label="Enter when branch result"]; + 265 [label="Exit when branch result"]; + 266 [label="Enter when branch result"]; subgraph cluster_84 { color=blue - 268 [label="Enter block"]; - 269 [label="Access variable R|kotlin/String.length|"]; - 270 [label="Exit block"]; + 267 [label="Enter block"]; + 268 [label="Access variable R|kotlin/String.length|"]; + 269 [label="Exit block"]; } - 271 [label="Exit when branch result"]; - 272 [label="Enter when branch result"]; + 270 [label="Exit when branch result"]; + 271 [label="Enter when branch result"]; subgraph cluster_85 { color=blue - 273 [label="Enter block"]; - 274 [label="Access variable R|SubstitutionOverride|"]; - 275 [label="Exit block"]; + 272 [label="Enter block"]; + 273 [label="Access variable R|SubstitutionOverride|"]; + 274 [label="Exit block"]; } - 276 [label="Exit when branch result"]; - 277 [label="Exit when"]; + 275 [label="Exit when branch result"]; + 276 [label="Exit when"]; } - 278 [label="Jump: ^test_5 when () { + 277 [label="Jump: ^test_5 when () { (this@R|/test_5| is R|kotlin/collections/List<*>|) -> { this@R|/test_5|.R|SubstitutionOverride| } @@ -809,62 +807,63 @@ digraph implicitReceivers_kt { } } "]; - 279 [label="Stub" style="filled" fillcolor=gray]; - 280 [label="Exit block" style="filled" fillcolor=gray]; + 278 [label="Stub" style="filled" fillcolor=gray]; + 279 [label="Exit block" style="filled" fillcolor=gray]; } - 281 [label="Exit function test_5" style="filled" fillcolor=red]; + 280 [label="Exit function test_5" style="filled" fillcolor=red]; } + 248 -> {249}; 249 -> {250}; 250 -> {251}; 251 -> {252}; 252 -> {253}; 253 -> {254}; - 254 -> {255}; - 255 -> {256 272}; + 254 -> {255 271}; + 255 -> {256}; 256 -> {257}; 257 -> {258}; - 258 -> {259}; - 259 -> {260 267}; + 258 -> {259 266}; + 259 -> {260}; 260 -> {261}; 261 -> {262}; 262 -> {263}; 263 -> {264}; 264 -> {265}; - 265 -> {266}; - 266 -> {277}; + 265 -> {276}; + 266 -> {267}; 267 -> {268}; 268 -> {269}; 269 -> {270}; - 270 -> {271}; - 271 -> {277}; + 270 -> {276}; + 271 -> {272}; 272 -> {273}; 273 -> {274}; 274 -> {275}; 275 -> {276}; 276 -> {277}; - 277 -> {278}; - 278 -> {281}; + 277 -> {280}; + 277 -> {278} [style=dotted]; 278 -> {279} [style=dotted]; 279 -> {280} [style=dotted]; - 280 -> {281} [style=dotted]; subgraph cluster_86 { color=red - 282 [label="Enter function test_6" style="filled" fillcolor=red]; + 281 [label="Enter function test_6" style="filled" fillcolor=red]; subgraph cluster_87 { color=blue - 283 [label="Enter block"]; - 284 [label="Access variable this@R|/test_6|"]; - 285 [label="Type operator: (this@R|/test_6| as R|kotlin/collections/List<*>|)"]; - 286 [label="Access variable R|SubstitutionOverride|"]; - 287 [label="Access variable this@R|/test_6|"]; - 288 [label="Smart cast: this@R|/test_6|"]; - 289 [label="Type operator: (this@R|/test_6| as R|kotlin/String|)"]; - 290 [label="Access variable R|kotlin/String.length|"]; - 291 [label="Exit block"]; + 282 [label="Enter block"]; + 283 [label="Access variable this@R|/test_6|"]; + 284 [label="Type operator: (this@R|/test_6| as R|kotlin/collections/List<*>|)"]; + 285 [label="Access variable R|SubstitutionOverride|"]; + 286 [label="Access variable this@R|/test_6|"]; + 287 [label="Smart cast: this@R|/test_6|"]; + 288 [label="Type operator: (this@R|/test_6| as R|kotlin/String|)"]; + 289 [label="Access variable R|kotlin/String.length|"]; + 290 [label="Exit block"]; } - 292 [label="Exit function test_6" style="filled" fillcolor=red]; + 291 [label="Exit function test_6" style="filled" fillcolor=red]; } + 281 -> {282}; 282 -> {283}; 283 -> {284}; 284 -> {285}; @@ -874,6 +873,5 @@ digraph implicitReceivers_kt { 288 -> {289}; 289 -> {290}; 290 -> {291}; - 291 -> {292}; } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.fir.txt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.fir.txt index a4008d940d7..d1cd23534a3 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.fir.txt @@ -50,16 +50,16 @@ FILE: implicitReceivers.kt #() } public final fun test_3(a: R|kotlin/Any|, b: R|kotlin/Any|, c: R|kotlin/Any|): R|kotlin/Unit| { - R|kotlin/with|(R|/a|, = wa@fun R|kotlin/Any|.(): R|kotlin/Unit| { - R|kotlin/with|(R|/b|, = wb@fun R|kotlin/Any|.(): R|kotlin/Unit| { + R|kotlin/with#|>(R|/a|, = wa@fun R|kotlin/Any|.(): { + ^ R|kotlin/with#|>(R|/b|, = wb@fun R|kotlin/Any|.(): { R|kotlin/with|(R|/c|, = wc@fun R|kotlin/Any|.(): R|kotlin/Unit| { (this@R|special/anonymous| as R|A|) this@R|special/anonymous|.R|/A.foo|() this@R|special/anonymous|.R|/A.foo|() } ) - this@R|special/anonymous|.R|/A.foo|() - this@R|special/anonymous|.R|/A.foo|() + this@R|special/anonymous|.#() + ^ #() } ) } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.kt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.kt index b1ddb729fcc..e3c433a879e 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.kt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/receivers/implicitReceivers.kt @@ -34,15 +34,15 @@ fun Any?.test_2() { } fun test_3(a: Any, b: Any, c: Any) { - with(a) wa@{ + with(a) wa@{ with(b) wb@{ with(c) wc@{ this@wb as A this@wb.foo() foo() } - this.foo() - foo() + this.foo() + foo() } } } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/safeCalls/safeCalls.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/safeCalls/safeCalls.dot index 95489615aa3..f8a8fb7be43 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/safeCalls/safeCalls.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/safeCalls/safeCalls.dot @@ -256,7 +256,7 @@ digraph safeCalls_kt { 79 -> {80}; 80 -> {81}; 82 -> {84}; - 83 -> {84}; + 83 -> {84} [label="Postponed"]; 84 -> {87}; 85 -> {86}; 86 -> {87}; @@ -407,7 +407,7 @@ digraph safeCalls_kt { 127 -> {128} [style=dotted]; 128 -> {130} [style=dotted]; 129 -> {131} [style=dotted]; - 130 -> {131} [style=dotted]; + 130 -> {131} [style=dotted label="Postponed"]; 131 -> {132} [style=dotted]; 132 -> {133 142} [style=dotted]; 133 -> {134} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastToNothing.dot b/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastToNothing.dot index 599d2ae0226..3d5ff2c5beb 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastToNothing.dot +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastToNothing.dot @@ -340,7 +340,7 @@ digraph smartcastToNothing_kt { 110 -> {111}; 111 -> {113}; 112 -> {114}; - 113 -> {114}; + 113 -> {114} [label="Postponed"]; 114 -> {115}; 115 -> {116}; 116 -> {117}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/complexPostponedCfg.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/complexPostponedCfg.dot index b1db8a3c272..0f4105ff9a8 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/complexPostponedCfg.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/complexPostponedCfg.dot @@ -176,18 +176,18 @@ digraph complexPostponedCfg_kt { 43 -> {44}; 44 -> {46}; 45 -> {47}; - 46 -> {47}; + 46 -> {47} [label="Postponed"]; 47 -> {48}; 48 -> {49}; 49 -> {51}; 50 -> {52}; 51 -> {52} [color=green]; - 51 -> {57} [color=red]; + 51 -> {57} [color=red label="Postponed"]; 52 -> {53}; 53 -> {54}; 54 -> {56}; 55 -> {57}; - 56 -> {57}; + 56 -> {57} [label="Postponed"]; 57 -> {58}; 58 -> {59}; 59 -> {60}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromLibrary/callsInPlace.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromLibrary/callsInPlace.dot index 44b38a8bd8a..a29c04f0997 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromLibrary/callsInPlace.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromLibrary/callsInPlace.dot @@ -62,7 +62,7 @@ digraph callsInPlace_kt { 11 -> {12}; 12 -> {14}; 13 -> {15}; - 14 -> {15}; + 14 -> {15} [label="Postponed"]; 15 -> {16}; 16 -> {17}; 17 -> {18}; @@ -112,8 +112,8 @@ digraph callsInPlace_kt { 30 -> {31}; 31 -> {33}; 32 -> {34}; - 33 -> {34}; 33 -> {26} [color=green style=dashed]; + 33 -> {34} [label="Postponed"]; 34 -> {35}; 35 -> {36}; @@ -159,8 +159,8 @@ digraph callsInPlace_kt { 45 -> {46}; 46 -> {48}; 47 -> {49}; - 48 -> {49}; 48 -> {41} [color=green style=dashed]; + 48 -> {49} [label="Postponed"]; 49 -> {50}; 50 -> {51}; @@ -222,7 +222,7 @@ digraph callsInPlace_kt { 66 -> {67}; 67 -> {69}; 68 -> {70}; - 69 -> {70}; + 69 -> {70} [label="Postponed"]; 70 -> {71}; 71 -> {72}; @@ -284,7 +284,7 @@ digraph callsInPlace_kt { 87 -> {88}; 88 -> {90}; 89 -> {91}; - 90 -> {91}; + 90 -> {91} [label="Postponed"]; 91 -> {92}; 92 -> {93}; @@ -377,10 +377,10 @@ digraph callsInPlace_kt { 116 -> {117}; 117 -> {120}; 118 -> {121}; - 119 -> {121}; 119 -> {107} [color=green style=dashed]; - 120 -> {121}; + 119 -> {121} [label="Postponed"]; 120 -> {107} [color=green style=dashed]; + 120 -> {121} [label="Postponed"]; 121 -> {122}; 122 -> {123}; @@ -441,10 +441,10 @@ digraph callsInPlace_kt { 136 -> {137}; 137 -> {140}; 138 -> {141}; - 139 -> {141}; 139 -> {127} [color=green style=dashed]; - 140 -> {141}; + 139 -> {141} [label="Postponed"]; 140 -> {127} [color=green style=dashed]; + 140 -> {141} [label="Postponed"]; 141 -> {142}; 142 -> {143}; @@ -510,7 +510,7 @@ digraph callsInPlace_kt { 157 -> {158}; 158 -> {159}; 160 -> {162}; - 161 -> {162}; + 161 -> {162} [label="Postponed"]; 162 -> {163}; 163 -> {164}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atLeastOnce.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atLeastOnce.dot index 090eebcfaa3..75a28e8a017 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atLeastOnce.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atLeastOnce.dot @@ -122,8 +122,8 @@ digraph atLeastOnce_kt { 29 -> {30}; 30 -> {32}; 31 -> {33}; - 32 -> {33}; 32 -> {24} [color=green style=dashed]; + 32 -> {33} [label="Postponed"]; 33 -> {34}; 34 -> {35}; 35 -> {36}; @@ -183,8 +183,8 @@ digraph atLeastOnce_kt { 49 -> {50}; 50 -> {52}; 51 -> {53}; - 52 -> {53}; 52 -> {44} [color=green style=dashed]; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55}; 55 -> {56}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atMostOnce.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atMostOnce.dot index b199c844318..a9766a3c415 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atMostOnce.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/atMostOnce.dot @@ -121,7 +121,7 @@ digraph atMostOnce_kt { 29 -> {30}; 30 -> {32}; 31 -> {33}; - 32 -> {33}; + 32 -> {33} [label="Postponed"]; 33 -> {34}; 34 -> {35}; 35 -> {36}; @@ -180,7 +180,7 @@ digraph atMostOnce_kt { 49 -> {50}; 50 -> {52}; 51 -> {53}; - 52 -> {53}; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55}; 55 -> {56}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/exactlyOnce.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/exactlyOnce.dot index 264e365db67..685a532dc90 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/exactlyOnce.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/exactlyOnce.dot @@ -122,7 +122,7 @@ digraph exactlyOnce_kt { 29 -> {30}; 30 -> {32}; 31 -> {33}; - 32 -> {33}; + 32 -> {33} [label="Postponed"]; 33 -> {34}; 34 -> {35}; 35 -> {36}; @@ -182,7 +182,7 @@ digraph exactlyOnce_kt { 49 -> {50}; 50 -> {52}; 51 -> {53}; - 52 -> {53}; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55}; 55 -> {56}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/inPlaceLambda.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/inPlaceLambda.dot index 4a69c65493b..59aa998d6f0 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/inPlaceLambda.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/inPlaceLambda.dot @@ -132,7 +132,7 @@ digraph inPlaceLambda_kt { 35 -> {36}; 36 -> {38}; 37 -> {39}; - 38 -> {39}; + 38 -> {39} [label="Postponed"]; 39 -> {40}; 40 -> {41}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/unknown.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/unknown.dot index ad82787208c..764e90cbcd3 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/unknown.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/contracts/fromSource/good/callsInPlace/unknown.dot @@ -121,8 +121,8 @@ digraph unknown_kt { 29 -> {30}; 30 -> {32}; 31 -> {33}; - 32 -> {33}; 32 -> {24} [color=green style=dashed]; + 32 -> {33} [label="Postponed"]; 33 -> {34}; 34 -> {35}; 35 -> {36}; @@ -181,8 +181,8 @@ digraph unknown_kt { 49 -> {50}; 50 -> {52}; 51 -> {53}; - 52 -> {53}; 52 -> {44} [color=green style=dashed]; + 52 -> {53} [label="Postponed"]; 53 -> {54}; 54 -> {55}; 55 -> {56}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/delegates/delegateWithAnonymousObject.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/delegates/delegateWithAnonymousObject.dot index 7baa8e4520f..9abc438fe2d 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/delegates/delegateWithAnonymousObject.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/delegates/delegateWithAnonymousObject.dot @@ -229,7 +229,7 @@ digraph delegateWithAnonymousObject_kt { 60 -> {61} [style=dotted]; 62 -> {64}; 63 -> {64} [color=green]; - 63 -> {68} [color=red]; + 63 -> {68} [color=red label="Postponed"]; 64 -> {65}; 65 -> {66}; 66 -> {67}; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/inference/plusAssignWithLambdaInRhs.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/inference/plusAssignWithLambdaInRhs.dot index 27721aaabaa..81163b0cfb7 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/inference/plusAssignWithLambdaInRhs.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/inference/plusAssignWithLambdaInRhs.dot @@ -52,7 +52,7 @@ digraph plusAssignWithLambdaInRhs_kt { 11 -> {12} [style=dotted]; 12 -> {13} [style=dotted]; 13 -> {14} [style=dotted]; - 15 -> {16} [style=dotted]; + 15 -> {16} [style=dotted label="Postponed"]; 16 -> {17} [style=dotted]; 17 -> {18} [style=dotted]; @@ -175,11 +175,11 @@ digraph plusAssignWithLambdaInRhs_kt { 45 -> {46}; 46 -> {47}; 47 -> {48}; - 49 -> {50}; + 49 -> {50} [label="Postponed"]; 50 -> {51}; 51 -> {52}; 53 -> {55}; - 54 -> {55}; + 54 -> {55} [label="Postponed"]; 55 -> {56}; 56 -> {59}; 56 -> {57} [style=dotted]; diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/smartcasts/tryWithLambdaInside.dot b/compiler/fir/analysis-tests/testData/resolveWithStdlib/smartcasts/tryWithLambdaInside.dot index fc069b94662..ee5347c4173 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/smartcasts/tryWithLambdaInside.dot +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/smartcasts/tryWithLambdaInside.dot @@ -128,7 +128,7 @@ finally { 26 -> {28}; 27 -> {20} [color=green style=dashed]; 27 -> {28} [color=green]; - 27 -> {35} [color=red]; + 27 -> {35} [color=red label="Postponed"]; 28 -> {29}; 29 -> {30}; 30 -> {31}; @@ -223,7 +223,7 @@ finally { 51 -> {52}; 53 -> {55}; 54 -> {55} [color=green]; - 54 -> {62} [color=red]; + 54 -> {62} [color=red label="Postponed"]; 55 -> {56}; 56 -> {57}; 57 -> {58}; diff --git a/compiler/fir/checkers/src/org/jetbrains/kotlin/fir/analysis/cfa/util/PathAwareControlFlowGraphVisitor.kt b/compiler/fir/checkers/src/org/jetbrains/kotlin/fir/analysis/cfa/util/PathAwareControlFlowGraphVisitor.kt index d8efc44c839..2264d09c69f 100644 --- a/compiler/fir/checkers/src/org/jetbrains/kotlin/fir/analysis/cfa/util/PathAwareControlFlowGraphVisitor.kt +++ b/compiler/fir/checkers/src/org/jetbrains/kotlin/fir/analysis/cfa/util/PathAwareControlFlowGraphVisitor.kt @@ -55,8 +55,9 @@ abstract class PathAwareControlFlowGraphVisitor> : persistentMapOf(NormalPath to info) } } - // A normal path forwards all data. (Non-normal paths should only have data in finally blocks.) + // A normal or postponed path forwards all data. (Non-normal paths should only have data in finally blocks.) label == NormalPath -> data + label == PostponedPath -> data // Labeled edge from a jump statement to a `finally` block forks flow. Usually we'd only have // NormalPath data here, but technically it's possible (though questionable) to jump from a `finally` // (discarding the exception or aborting a previous jump in the process) so merge all data just in case. diff --git a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/FirDataFlowAnalyzer.kt b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/FirDataFlowAnalyzer.kt index cfab0036fe5..3267f22330f 100644 --- a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/FirDataFlowAnalyzer.kt +++ b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/FirDataFlowAnalyzer.kt @@ -1280,23 +1280,32 @@ abstract class FirDataFlowAnalyzer( private fun CFGNode<*>.buildDefaultFlow( builder: (FlowPath, MutableFlow) -> Unit, ): MutableFlow { - val previousFlows = previousNodes.mapNotNull { node -> + val previousFlows = mutableListOf() + val statementFlows = mutableListOf() + + for (node in previousNodes) { val edge = edgeFrom(node) - if (!usedInDfa(edge)) return@mapNotNull null + if (!usedInDfa(edge)) continue // `MergePostponedLambdaExitsNode` nodes form a parallel data flow graph. We never compute // data flow for any of them until reaching a completed call. if (node is MergePostponedLambdaExitsNode && !node.flowInitialized) node.mergeIncomingFlow() // For CFGNodes that are the end of alternate flows, use the alternate flow associated with the edge label. - if (node is FinallyBlockExitNode) { + val flow = if (node is FinallyBlockExitNode) { val alternatePath = FlowPath.CfgEdge(edge.label, node.fir) node.getAlternateFlow(alternatePath) ?: node.flow } else { node.flow } + previousFlows.add(flow) + if (edge.label != PostponedPath) { + statementFlows.add(flow) + } } - val result = logicSystem.joinFlow(previousFlows, isUnion) + + val result = logicSystem.joinFlow(previousFlows, statementFlows, isUnion) + if (graphBuilder.lastNodeOrNull == this) { // Here it is, the new `lastNode`. If the previous state is the only predecessor, then there is actually // nothing to update; `addTypeStatement` has already ensured we have the correct information. @@ -1305,7 +1314,9 @@ abstract class FirDataFlowAnalyzer( } currentReceiverState = result } - return result.also { builder(FlowPath.Default, it) } + + builder(FlowPath.Default, result) + return result } private fun CFGNode<*>.buildAlternateFlow( @@ -1313,25 +1324,34 @@ abstract class FirDataFlowAnalyzer( builder: (FlowPath, MutableFlow) -> Unit, ): MutableFlow { val alternateFlowStart = this is FinallyBlockEnterNode - val previousFlows = previousNodes.mapNotNull { node -> + val previousFlows = mutableListOf() + val statementFlows = mutableListOf() + + for (node in previousNodes) { val edge = edgeFrom(node) - if (!usedInDfa(edge)) return@mapNotNull null + if (!usedInDfa(edge)) continue // For CFGNodes that cause alternate flow paths to be created, only edges with matching labels should be merged. However, when // an alternate flow is being propagated through one of these CFGNodes - i.e., when the FirElements do not match - only // NormalPath edges should be merged. if (alternateFlowStart) { if (path.fir == this.fir && edge.label != path.label) { - return@mapNotNull null + continue } else if (path.fir != this.fir && edge.label != NormalPath) { - return@mapNotNull null + continue } } - node.getAlternateFlow(path) ?: node.flow + val flow = node.getAlternateFlow(path) ?: node.flow + previousFlows.add(flow) + if (edge.label != PostponedPath) { + statementFlows.add(flow) + } } - val result = logicSystem.joinFlow(previousFlows, isUnion) - return result.also { builder(path, it) } + + val result = logicSystem.joinFlow(previousFlows, statementFlows, isUnion) + builder(path, result) + return result } // Generally when calling some method on `graphBuilder`, one of the nodes it returns is the new `lastNode`. diff --git a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraphBuilder.kt b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraphBuilder.kt index 4a8bf660f32..92f74315328 100644 --- a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraphBuilder.kt +++ b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraphBuilder.kt @@ -333,7 +333,7 @@ class ControlFlowGraphBuilder { if (kind.usedInCfa || !exit.isDead) { // Since `node` is a union node, it is dead iff any input is dead. For once, `propagateDeadness` // semantics are correct without an `updateDeadStatus`. - addEdge(exit, node, preferredKind = kind) + addEdge(exit, node, label = PostponedPath, preferredKind = kind) } } } @@ -381,7 +381,7 @@ class ControlFlowGraphBuilder { } else { for ((exit, kind) in currentLevelExits) { // `node` is a merge node for many inputs anyhow so someone will call `updateDeadStatus` on it. - addEdge(exit, node, preferredKind = kind, propagateDeadness = false) + addEdge(exit, node, label = PostponedPath, preferredKind = kind, propagateDeadness = false) } } } diff --git a/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/LogicSystem.kt b/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/LogicSystem.kt index 54a2f9cdee5..c0ecd0363c2 100644 --- a/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/LogicSystem.kt +++ b/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/LogicSystem.kt @@ -21,7 +21,15 @@ abstract class LogicSystem(private val context: ConeInferenceContext) { return !isNullableNothing } - fun joinFlow(flows: Collection, union: Boolean): MutableFlow { + /** + * Creates the next [Flow] by joining a set of previous [Flow]s. + * + * @param flows All [PersistentFlow]s which flow into the join flow. These will determine assignments and variable aliases for the + * resulting join flow. + * @param statementFlows A *subset* of [flows] used to determine what [TypeStatement]s will be copied to the join flow. + * @param union Determines if [TypeStatement]s from different flows should be combined with union or intersection logic. + */ + fun joinFlow(flows: Collection, statementFlows: Collection, union: Boolean): MutableFlow { when (flows.size) { 0 -> return MutableFlow() 1 -> return flows.first().fork() @@ -37,7 +45,7 @@ abstract class LogicSystem(private val context: ConeInferenceContext) { } else { result.copyCommonAliases(flows) } - result.copyStatements(flows, commonFlow, union) + result.copyStatements(statementFlows, commonFlow, union) // TODO: compute common implications? return result } diff --git a/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraph.kt b/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraph.kt index 13fbfec828e..5ca965ef268 100644 --- a/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraph.kt +++ b/compiler/fir/semantics/src/org/jetbrains/kotlin/fir/resolve/dfa/cfg/ControlFlowGraph.kt @@ -106,6 +106,10 @@ object UncaughtExceptionPath : EdgeLabel { override val label: String get() = "onUncaughtException" } +object PostponedPath : EdgeLabel { + override val label: String get() = "Postponed" +} + enum class EdgeKind( val usedInDfa: Boolean, // propagate flow to alive nodes val usedInDeadDfa: Boolean, // propagate flow to dead nodes diff --git a/compiler/testData/codegen/box/smartCasts/kt44814.dot b/compiler/testData/codegen/box/smartCasts/kt44814.dot index e60350658f3..623ed1ec282 100644 --- a/compiler/testData/codegen/box/smartCasts/kt44814.dot +++ b/compiler/testData/codegen/box/smartCasts/kt44814.dot @@ -772,7 +772,7 @@ digraph kt44814_kt { 207 -> {209}; 208 -> {195} [color=green style=dashed]; 208 -> {209} [color=green]; - 208 -> {216} [style=dotted]; + 208 -> {216} [style=dotted label="Postponed"]; 209 -> {210}; 210 -> {211 215}; 211 -> {212}; @@ -817,7 +817,7 @@ digraph kt44814_kt { 246 -> {247 249}; 247 -> {248}; 248 -> {255}; - 249 -> {255} [color=red]; + 249 -> {255} [color=red label="Postponed"]; 250 -> {251}; 251 -> {252}; 252 -> {253}; diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/definiteReturn/singleReturnFromTry.dot b/compiler/testData/diagnostics/tests/controlFlowAnalysis/definiteReturn/singleReturnFromTry.dot index f79d5c486f6..0122752b11d 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/definiteReturn/singleReturnFromTry.dot +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/definiteReturn/singleReturnFromTry.dot @@ -84,8 +84,8 @@ digraph singleReturnFromTry_kt { 20 -> {21} [style=dotted]; 21 -> {23} [style=dotted]; 22 -> {24}; - 23 -> {24}; 23 -> {14} [color=green style=dashed]; + 23 -> {24} [label="Postponed"]; 24 -> {25} [style=dotted]; 25 -> {26} [style=dotted]; 26 -> {27} [style=dotted]; @@ -225,7 +225,7 @@ digraph singleReturnFromTry_kt { 59 -> {61}; 60 -> {51} [color=green style=dashed]; 60 -> {61} [color=green]; - 60 -> {69} [style=dotted]; + 60 -> {69} [style=dotted label="Postponed"]; 61 -> {62} [style=dotted]; 62 -> {63} [style=dotted]; 63 -> {64} [style=dotted]; @@ -321,8 +321,8 @@ digraph singleReturnFromTry_kt { 91 -> {92} [style=dotted]; 92 -> {94} [style=dotted]; 93 -> {95}; - 94 -> {95}; 94 -> {75} [color=green style=dashed]; + 94 -> {95} [label="Postponed"]; 95 -> {96} [style=dotted]; 96 -> {97} [style=dotted]; 97 -> {98} [style=dotted]; @@ -416,7 +416,7 @@ digraph singleReturnFromTry_kt { 113 -> {115}; 114 -> {105} [color=green style=dashed]; 114 -> {115} [color=green]; - 114 -> {129} [color=red]; + 114 -> {129} [color=red label="Postponed"]; 115 -> {116} [style=dotted]; 116 -> {117} [style=dotted]; 117 -> {118} [style=dotted]; diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedConstructorArguments.dot b/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedConstructorArguments.dot index cc4f671e850..9f747afae5d 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedConstructorArguments.dot +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedConstructorArguments.dot @@ -135,7 +135,7 @@ digraph delegatedConstructorArguments_kt { 12 -> {14}; 13 -> {6} [color=green style=dashed]; 13 -> {14} [color=green]; - 13 -> {15} [color=red]; + 13 -> {15} [color=red label="Postponed"]; 14 -> {15}; 15 -> {30} [color=green label="return@/Test.Test"]; 15 -> {45} [color=red]; @@ -153,7 +153,7 @@ digraph delegatedConstructorArguments_kt { 26 -> {28}; 27 -> {20} [color=green style=dashed]; 27 -> {28} [color=green]; - 27 -> {29} [color=red]; + 27 -> {29} [color=red label="Postponed"]; 28 -> {29}; 29 -> {30} [color=green label="return@/Test.Test"]; 29 -> {55} [color=red]; diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/smartCastInCatch.dot b/compiler/testData/diagnostics/tests/controlFlowAnalysis/smartCastInCatch.dot index 888a79aab80..c204eccc134 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/smartCastInCatch.dot +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/smartCastInCatch.dot @@ -467,7 +467,7 @@ digraph smartCastInCatch_fir_kt { 148 -> {150}; 149 -> {151}; 150 -> {151} [color=green]; - 150 -> {163} [color=red]; + 150 -> {163} [color=red label="Postponed"]; 151 -> {152}; 152 -> {153}; 153 -> {154 163}; diff --git a/compiler/testData/diagnostics/tests/smartCasts/castchecks/castInTryWithJump.dot b/compiler/testData/diagnostics/tests/smartCasts/castchecks/castInTryWithJump.dot index b83b8e765a3..21c713dc358 100644 --- a/compiler/testData/diagnostics/tests/smartCasts/castchecks/castInTryWithJump.dot +++ b/compiler/testData/diagnostics/tests/smartCasts/castchecks/castInTryWithJump.dot @@ -1062,7 +1062,7 @@ digraph castInTryWithJump_fir_kt { 344 -> {345} [style=dotted]; 345 -> {347} [style=dotted]; 346 -> {348} [style=dotted]; - 347 -> {348} [style=dotted]; + 347 -> {348} [style=dotted label="Postponed"]; 348 -> {349} [style=dotted]; 349 -> {350} [style=dotted]; 350 -> {351} [style=dotted]; diff --git a/compiler/testData/diagnostics/tests/smartCasts/ownerDeclaresBothModifies.fir.kt b/compiler/testData/diagnostics/tests/smartCasts/ownerDeclaresBothModifies.fir.kt index 9ae5656cade..332c35bd5c6 100644 --- a/compiler/testData/diagnostics/tests/smartCasts/ownerDeclaresBothModifies.fir.kt +++ b/compiler/testData/diagnostics/tests/smartCasts/ownerDeclaresBothModifies.fir.kt @@ -7,7 +7,7 @@ fun foo(arg: Int?) { x.hashCode() x = null } - if (x != null) x = 42 + if (x != null) x = 42 // Unsafe because of lambda x.hashCode() -} +} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/when/withSubjectVariable/capturingInInitializer.fir.kt b/compiler/testData/diagnostics/tests/when/withSubjectVariable/capturingInInitializer.fir.kt index 2f683f0339d..ebefd883d8f 100644 --- a/compiler/testData/diagnostics/tests/when/withSubjectVariable/capturingInInitializer.fir.kt +++ b/compiler/testData/diagnostics/tests/when/withSubjectVariable/capturingInInitializer.fir.kt @@ -10,13 +10,13 @@ fun testSafeCaptureVarInInitializer() { val s = when (val y = run { x = 42; 32 }) { 0 -> { - x.inc() // TODO fix smart casts for captured variables + x.inc() // TODO fix smart casts for captured variables "0" } else -> "!= 0" } - x.inc() // TODO fix smart casts for captured variables + x.inc() // TODO fix smart casts for captured variables } diff --git a/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.fir.kt b/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.fir.kt deleted file mode 100644 index 472cdcd7b70..00000000000 --- a/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.fir.kt +++ /dev/null @@ -1,48 +0,0 @@ -// !LANGUAGE: +VariableDeclarationInWhenSubject - -fun foo(s1: Int, s2: Int) = s1 + s2 - -fun test1(x: String?) = - when (val y = x?.length) { - null -> 0 - else -> foo(x.length, y) - } - -fun test2(x: String?) { - when (val y = run { x!! }) { - "foo" -> x.length - "bar" -> y.length - } -} - -fun test3(x: String?, y: String?) { - when (val z = x ?: y!!) { - "foo" -> x.length - "bar" -> y.length - "baz" -> z.length - } -} - -fun id(x: T): T = x - -fun test4(x: String?) { - when (val y = id(x!!)) { - "foo" -> x.length - "bar" -> y.length - } -} - -class Inv(val data: T) - -fun test5(x: Inv) { - when (val y = x.data) { - is String -> y.length // should be ok - null -> x.data.length // should be error - } -} - -fun test6(x: Inv) { - when (val y = x.data) { - is String -> x.data.length // should be ok - } -} diff --git a/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.kt b/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.kt index 198e47e358c..b889f6dbc39 100644 --- a/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.kt +++ b/compiler/testData/diagnostics/tests/when/withSubjectVariable/smartCastOnValueBoundToSubjectVariable.kt @@ -1,11 +1,13 @@ +// FIR_IDENTICAL // !LANGUAGE: +VariableDeclarationInWhenSubject +// DIAGNOSTICS: -DEBUG_INFO_SMARTCAST fun foo(s1: Int, s2: Int) = s1 + s2 fun test1(x: String?) = when (val y = x?.length) { null -> 0 - else -> foo(x.length, y) + else -> foo(x.length, y) } fun test2(x: String?) { @@ -27,7 +29,7 @@ fun id(x: T): T = x fun test4(x: String?) { when (val y = id(x!!)) { - "foo" -> x.length + "foo" -> x.length "bar" -> y.length } } @@ -36,13 +38,13 @@ class Inv(val data: T) fun test5(x: Inv) { when (val y = x.data) { - is String -> y.length // should be ok + is String -> y.length // should be ok null -> x.data.length // should be error } } fun test6(x: Inv) { when (val y = x.data) { - is String -> x.data.length // should be ok + is String -> x.data.length // should be ok } } diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.fir.kt deleted file mode 100644 index d7f45912906..00000000000 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.fir.kt +++ /dev/null @@ -1,27 +0,0 @@ -// !LANGUAGE: +ReadDeserializedContracts +UseReturnsEffect -// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER - -fun testRequireSmartcast(x: Any?) { - require(x is String) - x.length -} - -fun testRequireUnreachableCode() { - require(false) - println("Can't get here!") -} - -fun testRequireWithMessage(x: Any?) { - require(x is String) { "x is not String!" } - x.length -} - -fun testRequireWithFailingMessage(x: Any?) { - require(x is String) { throw kotlin.IllegalStateException("What a strange idea") } - x.length -} - -fun tesRequireNotNullWithMessage(x: Int?) { - requireNotNull(x) { "x is null!"} - x.inc() -} \ No newline at end of file diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.kt index 783fb01c185..2bb10fa3cb3 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.kt @@ -1,9 +1,11 @@ -// !LANGUAGE: +ReadDeserializedContracts +UseReturnsEffect -// !DIAGNOSTICS: -INVISIBLE_REFERENCE -INVISIBLE_MEMBER +// FIR_IDENTICAL +// LANGUAGE: +ReadDeserializedContracts +UseReturnsEffect +// DIAGNOSTICS: -INVISIBLE_REFERENCE, -INVISIBLE_MEMBER, -DEBUG_INFO_SMARTCAST +// SKIP_TXT fun testRequireSmartcast(x: Any?) { require(x is String) - x.length + x.length } fun testRequireUnreachableCode() { @@ -13,15 +15,34 @@ fun testRequireUnreachableCode() { fun testRequireWithMessage(x: Any?) { require(x is String) { "x is not String!" } - x.length + x.length } fun testRequireWithFailingMessage(x: Any?) { require(x is String) { throw kotlin.IllegalStateException("What a strange idea") } - x.length + x.length } fun tesRequireNotNullWithMessage(x: Int?) { requireNotNull(x) { "x is null!"} - x.inc() -} \ No newline at end of file + x.inc() +} + +fun testRequireAndDefiniteReturn(x: Any, b: Boolean) { + if (b) { + require(x is String) + } else { + return + } + x.length +} + + +fun testRequireWithFailingMessageAndDefiniteReturn(x: Any, b: Boolean) { + if (b) { + require(x is String) { "x is not String!" } + } else { + return + } + x.length +} diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.txt b/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.txt deleted file mode 100644 index 9bdc1eca469..00000000000 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/fromStdlib/require.txt +++ /dev/null @@ -1,7 +0,0 @@ -package - -public fun tesRequireNotNullWithMessage(/*0*/ x: kotlin.Int?): kotlin.Unit -public fun testRequireSmartcast(/*0*/ x: kotlin.Any?): kotlin.Unit -public fun testRequireUnreachableCode(): kotlin.Unit -public fun testRequireWithFailingMessage(/*0*/ x: kotlin.Any?): kotlin.Unit -public fun testRequireWithMessage(/*0*/ x: kotlin.Any?): kotlin.Unit diff --git a/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letAlwaysChangesToNotNull.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letAlwaysChangesToNotNull.fir.kt index 3fa4b2468ec..137f43816f5 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letAlwaysChangesToNotNull.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letAlwaysChangesToNotNull.fir.kt @@ -3,5 +3,5 @@ fun foo(y: String) { var x: String? = null y.let { x = it } - x.length // Smart cast is not possible + x.length // Smart cast is not possible } diff --git a/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letMergeNotNull.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letMergeNotNull.fir.kt index 833bb2fecce..be19cc5cfd9 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letMergeNotNull.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/smartcasts/letMergeNotNull.fir.kt @@ -4,6 +4,6 @@ fun foo(y: String?) { var x: String? = null if (x != null) { y?.let { x = it } - x.length // not-null or not-null + x.length // not-null or not-null } } diff --git a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.fir.kt b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.fir.kt deleted file mode 100644 index a1499e67e3f..00000000000 --- a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.fir.kt +++ /dev/null @@ -1,39 +0,0 @@ -// !OPT_IN: kotlin.contracts.ExperimentalContracts -// SKIP_TXT - -/* - * KOTLIN DIAGNOSTICS NOT LINKED SPEC TEST (POSITIVE) - * - * SECTIONS: contracts, analysis, smartcasts - * NUMBER: 12 - * DESCRIPTION: Smartcasts after non-null assertions or not-null value assignment in lambdas of contract function with 'exactly once' or 'at least once' CallsInPlace effects. - * UNEXPECTED BEHAVIOUR - * ISSUES: KT-26148 - * HELPERS: contractFunctions - */ - -// TESTCASE NUMBER: 1 -fun case_1(arg: Int?) { - funWithExactlyOnceCallsInPlace { arg!! } - arg.inc() -} - -// TESTCASE NUMBER: 2 -fun case_2(arg: Int?) { - funWithAtLeastOnceCallsInPlace { arg!! } - arg.inc() -} - -// TESTCASE NUMBER: 3 -fun case_3() { - val value_1: Boolean? - funWithExactlyOnceCallsInPlace { value_1 = false } - value_1.not() -} - -// TESTCASE NUMBER: 4 -fun case_4() { - val value_1: Boolean? - funWithAtLeastOnceCallsInPlace { value_1 = true } - value_1.not() -} diff --git a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.kt b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.kt index 775edc2f8bc..7297c394e21 100644 --- a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.kt +++ b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/pos/12.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // !OPT_IN: kotlin.contracts.ExperimentalContracts // SKIP_TXT