[WASM] Fix dce type removal for local variables
This commit is contained in:
+5
@@ -32,6 +32,11 @@ internal class WasmUsefulDeclarationProcessor(
|
|||||||
else -> Unit
|
else -> Unit
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun visitVariable(declaration: IrVariable, data: IrDeclaration) {
|
||||||
|
declaration.type.enqueueType(data, "local variable type")
|
||||||
|
super.visitVariable(declaration, data)
|
||||||
|
}
|
||||||
|
|
||||||
private fun tryToProcessIntrinsicCall(from: IrDeclaration, call: IrCall): Boolean = when (call.symbol) {
|
private fun tryToProcessIntrinsicCall(from: IrDeclaration, call: IrCall): Boolean = when (call.symbol) {
|
||||||
context.wasmSymbols.unboxIntrinsic -> {
|
context.wasmSymbols.unboxIntrinsic -> {
|
||||||
val fromType = call.getTypeArgument(0)
|
val fromType = call.getTypeArgument(0)
|
||||||
|
|||||||
Reference in New Issue
Block a user