[IR] Introduce new IdSignatures

FileSignature, CompositeSignature, LocalSignature

They are needed to make possible reference any non-local declaration via
 signature, including private signature, type parameters and so on.

- Support those new signatures in proto and klibs
- Rename `isPublic` -> `isPubliclyVisible` due to changed semantic
- Fix FIR
- clean up code
This commit is contained in:
Roman Artemev
2021-05-26 19:26:08 +03:00
committed by TeamCityServer
parent 7139785036
commit 6cdac22a23
58 changed files with 3271 additions and 1330 deletions
@@ -16,6 +16,7 @@ import org.jetbrains.kotlin.descriptors.impl.ModuleDescriptorImpl
import org.jetbrains.kotlin.generators.util.GeneratorsFileUtil
import org.jetbrains.kotlin.ir.declarations.impl.IrFactoryImpl
import org.jetbrains.kotlin.ir.descriptors.IrBuiltIns
import org.jetbrains.kotlin.ir.symbols.IrFileSymbol
import org.jetbrains.kotlin.ir.types.impl.originalKotlinType
import org.jetbrains.kotlin.ir.util.*
import org.jetbrains.kotlin.name.Name
@@ -264,6 +265,10 @@ private fun getIrBuiltIns(): IrBuiltIns {
override fun composeSignature(descriptor: DeclarationDescriptor): IdSignature? = null
override fun composeEnumEntrySignature(descriptor: ClassDescriptor): IdSignature? = null
override fun composeAnonInitSignature(descriptor: ClassDescriptor): IdSignature? = null
override fun composeFieldSignature(descriptor: PropertyDescriptor): IdSignature? = null
}
val symbolTable = SymbolTable(signaturer, IrFactoryImpl)
val typeTranslator = TypeTranslatorImpl(symbolTable, languageSettings, moduleDescriptor)