[JS] Fix typeOf for some reified type parameters

Fix getting kType metadata in cases when corresponding jsClass value
is passed through temporary variable.
This can happen when jsClass expression is not consided trivial by
local variable optimizer. This happens for object declarations from
different modules, for example kotlin.Unit
This commit is contained in:
Svyatoslav Kuzmich
2019-11-11 20:44:35 +03:00
parent c4d993d14c
commit 600fb723f4
4 changed files with 50 additions and 2 deletions
@@ -19316,6 +19316,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
public void testMultipleModules() throws Exception {
runTest("compiler/testData/codegen/box/reflection/typeOf/js/multipleModules.kt");
}
@TestMetadata("typeOfReifiedUnit.kt")
public void testTypeOfReifiedUnit() throws Exception {
runTest("compiler/testData/codegen/box/reflection/typeOf/js/typeOfReifiedUnit.kt");
}
}
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/noReflect")
@@ -20446,6 +20446,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
public void testMultipleModules() throws Exception {
runTest("compiler/testData/codegen/box/reflection/typeOf/js/multipleModules.kt");
}
@TestMetadata("typeOfReifiedUnit.kt")
public void testTypeOfReifiedUnit() throws Exception {
runTest("compiler/testData/codegen/box/reflection/typeOf/js/typeOfReifiedUnit.kt");
}
}
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/noReflect")