[JS IR] Minor: eliminate unused vals

This commit is contained in:
Alexander Korepanov
2022-08-25 16:57:37 +02:00
committed by Space
parent 57fdfbe860
commit ff2f16190d
2 changed files with 2 additions and 4 deletions
@@ -78,7 +78,6 @@ private fun JsNode.computeScopes(): Scope {
x.name?.let { currentScope.declaredNames += it }
val oldScope = currentScope
currentScope = Scope().apply {
parent = currentScope
currentScope.children += this
}
currentScope.declaredNames += x.parameters.map { it.name }
@@ -114,8 +113,7 @@ private fun JsNode.computeScopes(): Scope {
}
private class Scope {
var parent: Scope? = null
val declaredNames = mutableSetOf<JsName>()
val usedNames = mutableSetOf<JsName>()
val children = mutableSetOf<Scope>()
}
}
@@ -83,7 +83,7 @@ class NewNamerImpl(
val context: JsIrBackendContext,
val unit: IrToJs.CodegenUnit,
val exportId: (IrDeclarationWithName) -> String,
val stableNames: Set<String>,
stableNames: Set<String>,
) : IrNamerBase() {
val staticNames = NameTable<IrDeclaration>(
reserved = stableNames.toMutableSet()