Support generic underlying type of inline class

Use upper bound in JVM representation.
 #KT-32162
This commit is contained in:
Ilmir Usmanov
2021-12-09 03:37:17 +01:00
parent 732b8d4067
commit 9060168542
22 changed files with 326 additions and 12 deletions
@@ -17768,6 +17768,29 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
}
}
@TestMetadata("compiler/testData/codegen/box/inlineClasses/genericUnderlyingValue")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class GenericUnderlyingValue extends AbstractLightAnalysisModeTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
}
public void testAllFilesPresentInGenericUnderlyingValue() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/inlineClasses/genericUnderlyingValue"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true);
}
@TestMetadata("simple.kt")
public void testSimple() throws Exception {
runTest("compiler/testData/codegen/box/inlineClasses/genericUnderlyingValue/simple.kt");
}
@TestMetadata("upperBound.kt")
public void testUpperBound() throws Exception {
runTest("compiler/testData/codegen/box/inlineClasses/genericUnderlyingValue/upperBound.kt");
}
}
@TestMetadata("compiler/testData/codegen/box/inlineClasses/hiddenConstructor")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)