Generate metadata and annotations for hidden constructor

Reflection expects to see a callable method for a hidden constructor,
thus, it should be a synthetic accessor.
JVM method signature in metadata should point to the synthetic accessor.
Annotations for hidden constructor should be written on the synthetic
accessor.
This commit is contained in:
Dmitry Petrov
2018-09-11 18:08:22 +03:00
parent 3e3ffd14a9
commit 792c5f8b3f
16 changed files with 219 additions and 12 deletions
@@ -133,6 +133,11 @@ public class LoadJavaClsStubTestGenerated extends AbstractLoadJavaClsStubTest {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Getter.kt");
}
@TestMetadata("HiddenConstructorWithInlineClassParameters.kt")
public void testHiddenConstructorWithInlineClassParameters() throws Exception {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/HiddenConstructorWithInlineClassParameters.kt");
}
@TestMetadata("PropertyField.kt")
public void testPropertyField() throws Exception {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/PropertyField.kt");
@@ -133,6 +133,11 @@ public class ResolveByStubTestGenerated extends AbstractResolveByStubTest {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/Getter.kt");
}
@TestMetadata("HiddenConstructorWithInlineClassParameters.kt")
public void testHiddenConstructorWithInlineClassParameters() throws Exception {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/HiddenConstructorWithInlineClassParameters.kt");
}
@TestMetadata("PropertyField.kt")
public void testPropertyField() throws Exception {
runTest("compiler/testData/loadJava/compiledKotlin/annotations/classMembers/PropertyField.kt");