diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt5395.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt5395.kt new file mode 100644 index 00000000000..11bb02ddf09 --- /dev/null +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt5395.kt @@ -0,0 +1,13 @@ +class D { + companion object { + protected val F: String = "OK" + } + + inner class E { + fun foo() = F + } +} + +fun box(): String { + return D().E().foo() +} diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/generated/BlackBoxWithStdlibCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/generated/BlackBoxWithStdlibCodegenTestGenerated.java index 8d54ed47114..c9a30a0ac39 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/generated/BlackBoxWithStdlibCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/generated/BlackBoxWithStdlibCodegenTestGenerated.java @@ -3104,6 +3104,12 @@ public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCode doTestWithStdlib(fileName); } + @TestMetadata("kt5395.kt") + public void testKt5395() throws Exception { + String fileName = JetTestUtils.navigationMetadata("compiler/testData/codegen/boxWithStdlib/regressions/kt5395.kt"); + doTestWithStdlib(fileName); + } + @TestMetadata("kt6434.kt") public void testKt6434() throws Exception { String fileName = JetTestUtils.navigationMetadata("compiler/testData/codegen/boxWithStdlib/regressions/kt6434.kt");