[JS IR] Ignore unbound symbols in IC infrastructure

The IR linker is responsible for detecting unbound symbols,
 if it skips them for some reason, IC infrastructure must not fail
 with unbound symbols exceptions. Anyway, the IR validator
 verifies later if there are unbound symbols in
 reachable IR and generates the corresponding error.

^KT-56602 Fixed
This commit is contained in:
Alexander Korepanov
2023-02-20 11:54:47 +01:00
committed by Space Team
parent ff22f456a0
commit 3c9d653595
16 changed files with 101 additions and 13 deletions
@@ -0,0 +1,5 @@
interface GenericInterface<T>
interface TestInterface {
fun <T> test(f: () -> GenericInterface<out T>) {}
}
@@ -0,0 +1,5 @@
interface GenericInterface<out T>
interface TestInterface {
fun <T> test(f: () -> GenericInterface<T>) {}
}
@@ -0,0 +1,9 @@
STEP 0:
modifications:
U : l1.0.kt -> l1.kt
added file: l1.kt
STEP 1:
modifications:
U : l1.1.kt -> l1.kt
modified ir: l1.kt
updated exports: l1.kt
@@ -0,0 +1,5 @@
class TestClass : TestInterface {
override fun <T> test(f: () -> GenericInterface<out T>) {
f()
}
}
@@ -0,0 +1,8 @@
STEP 0:
dependencies: lib1
modifications:
U : l2.0.kt -> l2.kt
added file: l2.kt
STEP 1:
rebuild klib: false
updated imports: l2.kt
@@ -0,0 +1,16 @@
fun box(stepId: Int): String {
var x = -1
TestClass().test {
object : GenericInterface<Int> {
init {
x = stepId
}
}
}
when (stepId) {
in 0..1 -> if (x != stepId) return "Fail, got $x"
else -> return "Unknown"
}
return "OK"
}
@@ -0,0 +1,6 @@
STEP 0:
dependencies: lib1, lib2
added file: m.kt
STEP 1:
dependencies: lib1, lib2
updated imports: m.kt
@@ -0,0 +1,8 @@
MODULES: lib1, lib2, main
STEP 0:
libs: lib1, lib2, main
dirty js: lib1, lib2, main
STEP 1:
libs: lib1, lib2, main
dirty js: lib1, lib2, main