New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update filter for suspending lambdas for Kotlin 1.4.20 #1149
Conversation
While
due to integration of https://openjdk.java.net/jeps/396 There is already ticket https://youtrack.jetbrains.com/issue/KT-43704 For us I can imagine following options:
I think the last option is the best. @marchof WDYT? |
@Godin As option 2 is a global setting for the build I also prefer option 3. As soon as there is a Kotlin compiler that can cope with Java 16 we can re-enable Java 16 and 17. |
Imagined one more option: However AFAIK Kotlin doesn't generate different bytecode when targeting Java |
I wouldn't spend effort here. We just remove it from the profiles and make a comment about KT-43704 |
7ba6806
to
2e0c592
Compare
public final java.lang.Object invokeSuspend(java.lang.Object);
descriptor: (Ljava/lang/Object;)Ljava/lang/Object;
flags: ACC_PUBLIC, ACC_FINAL
Code:
- stack=3, locals=4, args_size=2
- 0: invokestatic #28 // Method kotlin/coroutines/intrinsics/IntrinsicsKt.getCOROUTINE_SUSPENDED:()Ljava/lang/Object;
- 3: astore_3
+ stack=3, locals=3, args_size=2
+ 0: invokestatic #26 // Method kotlin/coroutines/intrinsics/IntrinsicsKt.getCOROUTINE_SUSPENDED:()Ljava/lang/Object;
+ 3: astore_2
...
LineNumberTable:
line 4: 3
- line 5: 37
+ line 5: 32
LocalVariableTable:
Start Length Slot Name Signature
- 37 4 2 $this$runBlocking Lkotlinx/coroutines/CoroutineScope;
- 0 51 0 this LExampleKt$example$1;
- 0 51 1 $result Ljava/lang/Object;
+ 32 4 0 this LExampleKt$example$1;
+ 32 4 1 $result Ljava/lang/Object; So there seems to be a room for future improvement:
@marchof WDYT? Or maybe you have some other ideas? In any case I think that we should proceed here and merge as is, dealing with these potential improvements separately, so could you please review? |
Hi @Godin 👋! Thanks for the fix. I would prefer your proposal to make nextIs* behave identical also for the first node. Some more aspects that could be cleaned-up:
|
Fixes #1126