JVM_IR: skip SAM lambdas when computing enclosing method of objects

This is what Java 15+ does, and it permits accessing captured type
parameters via reflection. The alternative is to emit generic signatures
on the lambda methods, but that was disabled and I have no clue why.

^KT-52417 Fixed
This commit is contained in:
pyos
2022-05-24 09:23:41 +02:00
committed by Alexander Udalov
parent f81d47bad6
commit 27c51f5f88
21 changed files with 211 additions and 6 deletions
@@ -35870,6 +35870,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
runTest("compiler/testData/codegen/box/sam/kt50171.kt");
}
@TestMetadata("kt52417.kt")
public void testKt52417() throws Exception {
runTest("compiler/testData/codegen/box/sam/kt52417.kt");
}
@TestMetadata("nonInlinedSamWrapper.kt")
public void testNonInlinedSamWrapper() throws Exception {
runTest("compiler/testData/codegen/box/sam/nonInlinedSamWrapper.kt");