[IR] Refactor ir infrastructure

- Remove range-based uniq id indexes using to link built ins
 - Limit KotlinType usages, replace them with corresponding IrType
This commit is contained in:
Roman Artemev
2019-10-28 10:50:15 +03:00
committed by romanart
parent 90d07eee53
commit a343a57207
22 changed files with 409 additions and 232 deletions
@@ -41,6 +41,6 @@ class JsUniqIdClashTracker : UniqIdClashTracker {
class JsGlobalDeclarationTable(builtIns: IrBuiltIns) : GlobalDeclarationTable(JsMangler, JsUniqIdClashTracker()) {
init {
loadKnownBuiltins(builtIns, PUBLIC_LOCAL_UNIQ_ID_EDGE)
loadKnownBuiltins(builtIns)
}
}
@@ -1,8 +0,0 @@
/*
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.ir.backend.js.lower.serialization.ir
internal const val PUBLIC_LOCAL_UNIQ_ID_EDGE = 0x7FFF_FFFF_FFFF_FFFFL + 1L
@@ -22,7 +22,7 @@ class JsIrLinker(
logger: LoggingContext,
builtIns: IrBuiltIns,
symbolTable: SymbolTable
) : KotlinIrLinker(logger, builtIns, symbolTable, emptyList(), null, PUBLIC_LOCAL_UNIQ_ID_EDGE),
) : KotlinIrLinker(logger, builtIns, symbolTable, emptyList(), null, mangler),
DescriptorUniqIdAware by DeserializedDescriptorUniqIdAware {
override val descriptorReferenceDeserializer =