Mark implicit receiver as captured if the function is expression

#KT-40260 Fixed
 #KT-42280 Fixed
This commit is contained in:
Ilmir Usmanov
2020-09-30 21:00:26 +02:00
parent 3078bd7b67
commit 5e02a4efd7
10 changed files with 141 additions and 1 deletions
@@ -6593,11 +6593,21 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
runTest("compiler/testData/codegen/box/coroutines/builderInferenceAndGenericArrayAcessCall.kt");
}
@TestMetadata("captureInfixFun.kt")
public void testCaptureInfixFun() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/captureInfixFun.kt");
}
@TestMetadata("captureMutableLocalVariableInsideCoroutineBlock.kt")
public void testCaptureMutableLocalVariableInsideCoroutineBlock() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/captureMutableLocalVariableInsideCoroutineBlock.kt");
}
@TestMetadata("captureUnaryOperator.kt")
public void testCaptureUnaryOperator() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/captureUnaryOperator.kt");
}
@TestMetadata("capturedVarInSuspendLambda.kt")
public void testCapturedVarInSuspendLambda_1_2() throws Exception {
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/capturedVarInSuspendLambda.kt", "kotlin.coroutines.experimental");