Use common instance receiver generation logic for 'this' expression

Otherwise it would skip private companion object accessor generation.
This commit is contained in:
Dmitry Petrov
2018-09-25 15:23:55 +03:00
parent c4337f753e
commit 7949ac1080
7 changed files with 75 additions and 23 deletions
@@ -13303,6 +13303,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/objects/companionObjectAccess"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JS_IR, true);
}
@TestMetadata("kt27117.kt")
public void testKt27117() throws Exception {
runTest("compiler/testData/codegen/box/objects/companionObjectAccess/kt27117.kt");
}
@TestMetadata("privateCompanionObjectAccessedFromAnonymousObjectInNestedClass.kt")
public void testPrivateCompanionObjectAccessedFromAnonymousObjectInNestedClass() throws Exception {
runTest("compiler/testData/codegen/box/objects/companionObjectAccess/privateCompanionObjectAccessedFromAnonymousObjectInNestedClass.kt");
@@ -14348,6 +14348,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/objects/companionObjectAccess"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JS, true);
}
@TestMetadata("kt27117.kt")
public void testKt27117() throws Exception {
runTest("compiler/testData/codegen/box/objects/companionObjectAccess/kt27117.kt");
}
@TestMetadata("privateCompanionObjectAccessedFromAnonymousObjectInNestedClass.kt")
public void testPrivateCompanionObjectAccessedFromAnonymousObjectInNestedClass() throws Exception {
runTest("compiler/testData/codegen/box/objects/companionObjectAccess/privateCompanionObjectAccessedFromAnonymousObjectInNestedClass.kt");