KLIB: changes in the .proto and linker required for the JS IC
The original behaviour is preserved. All changes should be behind the flags.
This commit is contained in:
committed by
teamcityserver
parent
002f4210f7
commit
3833c833ef
@@ -451,9 +451,9 @@ message IrOperation {
|
|||||||
IrErrorExpression error_expression = 34;
|
IrErrorExpression error_expression = 34;
|
||||||
IrErrorCallExpression error_call_expression = 35;
|
IrErrorCallExpression error_call_expression = 35;
|
||||||
|
|
||||||
IrRawFunctionReference raw_function_reference = 36;
|
IrRawFunctionReference raw_function_reference = 136;
|
||||||
IrReturnableBlock returnable_block = 37;
|
IrReturnableBlock returnable_block = 137;
|
||||||
IrReturnableBlockReturn returnable_block_return = 38;
|
IrReturnableBlockReturn returnable_block_return = 138;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -521,7 +521,7 @@ message IrField {
|
|||||||
message IrLocalDelegatedProperty {
|
message IrLocalDelegatedProperty {
|
||||||
required IrDeclarationBase base = 1;
|
required IrDeclarationBase base = 1;
|
||||||
required int64 name_type = 2;
|
required int64 name_type = 2;
|
||||||
required IrVariable delegate = 3;
|
optional IrVariable delegate = 3;
|
||||||
optional IrFunction getter = 4;
|
optional IrFunction getter = 4;
|
||||||
optional IrFunction setter = 5;
|
optional IrFunction setter = 5;
|
||||||
}
|
}
|
||||||
@@ -545,15 +545,15 @@ message IrValueParameter {
|
|||||||
required int64 name_type = 2;
|
required int64 name_type = 2;
|
||||||
optional int32 vararg_element_type = 3;
|
optional int32 vararg_element_type = 3;
|
||||||
optional int32 default_value = 4;
|
optional int32 default_value = 4;
|
||||||
optional int32 index = 5;
|
optional int32 index = 105;
|
||||||
}
|
}
|
||||||
|
|
||||||
message IrTypeParameter {
|
message IrTypeParameter {
|
||||||
required IrDeclarationBase base = 1;
|
required IrDeclarationBase base = 1;
|
||||||
required int32 name = 2;
|
required int32 name = 2;
|
||||||
repeated int32 super_type = 3 [packed=true];
|
repeated int32 super_type = 3 [packed=true];
|
||||||
optional int32 index = 4;
|
optional int32 index = 104;
|
||||||
optional bool isGlobal = 5;
|
optional bool isGlobal = 105;
|
||||||
}
|
}
|
||||||
|
|
||||||
message IrClass {
|
message IrClass {
|
||||||
|
|||||||
+6
-3
@@ -42,9 +42,11 @@ class FakeOverrideGlobalDeclarationTable(
|
|||||||
|
|
||||||
open class FakeOverrideDeclarationTable(
|
open class FakeOverrideDeclarationTable(
|
||||||
mangler: KotlinMangler.IrMangler,
|
mangler: KotlinMangler.IrMangler,
|
||||||
|
signatureSerializerFactory: (PublicIdSignatureComputer, DeclarationTable) -> IdSignatureSerializer,
|
||||||
globalTable: FakeOverrideGlobalDeclarationTable = FakeOverrideGlobalDeclarationTable(mangler)
|
globalTable: FakeOverrideGlobalDeclarationTable = FakeOverrideGlobalDeclarationTable(mangler)
|
||||||
) : DeclarationTable(globalTable) {
|
) : DeclarationTable(globalTable) {
|
||||||
override val globalDeclarationTable: FakeOverrideGlobalDeclarationTable = globalTable
|
override val globalDeclarationTable: FakeOverrideGlobalDeclarationTable = globalTable
|
||||||
|
override val signaturer: IdSignatureSerializer = signatureSerializerFactory(globalTable.publicIdSignatureComputer, this)
|
||||||
fun clear() {
|
fun clear() {
|
||||||
this.table.clear()
|
this.table.clear()
|
||||||
globalDeclarationTable.clear()
|
globalDeclarationTable.clear()
|
||||||
@@ -69,15 +71,16 @@ class FakeOverrideBuilder(
|
|||||||
val symbolTable: SymbolTable,
|
val symbolTable: SymbolTable,
|
||||||
mangler: KotlinMangler.IrMangler,
|
mangler: KotlinMangler.IrMangler,
|
||||||
typeSystem: IrTypeSystemContext,
|
typeSystem: IrTypeSystemContext,
|
||||||
|
irBuiltIns: IrBuiltIns,
|
||||||
val platformSpecificClassFilter: FakeOverrideClassFilter = DefaultFakeOverrideClassFilter,
|
val platformSpecificClassFilter: FakeOverrideClassFilter = DefaultFakeOverrideClassFilter,
|
||||||
// TODO: The declaration table is needed for the signaturer.
|
val signatureSerializerFactory: (PublicIdSignatureComputer, DeclarationTable) -> IdSignatureSerializer = ::IdSignatureSerializer,
|
||||||
private val fakeOverrideDeclarationTable: DeclarationTable = FakeOverrideDeclarationTable(mangler),
|
|
||||||
) : FakeOverrideBuilderStrategy() {
|
) : FakeOverrideBuilderStrategy() {
|
||||||
private val haveFakeOverrides = mutableSetOf<IrClass>()
|
private val haveFakeOverrides = mutableSetOf<IrClass>()
|
||||||
|
|
||||||
private val irOverridingUtil = IrOverridingUtil(typeSystem, this)
|
private val irOverridingUtil = IrOverridingUtil(typeSystem, this)
|
||||||
|
|
||||||
// private class CompatibilityMode(val oldSignatures: Boolean)
|
// TODO: The declaration table is needed for the signaturer.
|
||||||
|
private val fakeOverrideDeclarationTable = FakeOverrideDeclarationTable(mangler, signatureSerializerFactory)
|
||||||
|
|
||||||
private val fakeOverrideCandidates = mutableMapOf<IrClass, CompatibilityMode>()
|
private val fakeOverrideCandidates = mutableMapOf<IrClass, CompatibilityMode>()
|
||||||
fun enqueueClass(clazz: IrClass, signature: IdSignature, compatibilityMode: CompatibilityMode) {
|
fun enqueueClass(clazz: IrClass, signature: IdSignature, compatibilityMode: CompatibilityMode) {
|
||||||
|
|||||||
+7
-1
@@ -27,7 +27,8 @@ abstract class BasicIrModuleDeserializer(
|
|||||||
override val klib: IrLibrary,
|
override val klib: IrLibrary,
|
||||||
override val strategy: DeserializationStrategy,
|
override val strategy: DeserializationStrategy,
|
||||||
libraryAbiVersion: KotlinAbiVersion,
|
libraryAbiVersion: KotlinAbiVersion,
|
||||||
private val containsErrorCode: Boolean = false
|
private val containsErrorCode: Boolean = false,
|
||||||
|
private val useGlobalSignatures: Boolean = false,
|
||||||
) :
|
) :
|
||||||
IrModuleDeserializer(moduleDescriptor, libraryAbiVersion) {
|
IrModuleDeserializer(moduleDescriptor, libraryAbiVersion) {
|
||||||
|
|
||||||
@@ -41,6 +42,10 @@ abstract class BasicIrModuleDeserializer(
|
|||||||
moduleDescriptor.allDependencyModules.filter { it != moduleDescriptor }.map { linker.resolveModuleDeserializer(it, null) }
|
moduleDescriptor.allDependencyModules.filter { it != moduleDescriptor }.map { linker.resolveModuleDeserializer(it, null) }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun fileDeserializers(): Collection<IrFileDeserializer> {
|
||||||
|
return fileToDeserializerMap.values
|
||||||
|
}
|
||||||
|
|
||||||
override fun init(delegate: IrModuleDeserializer) {
|
override fun init(delegate: IrModuleDeserializer) {
|
||||||
val fileCount = klib.fileCount()
|
val fileCount = klib.fileCount()
|
||||||
|
|
||||||
@@ -114,6 +119,7 @@ abstract class BasicIrModuleDeserializer(
|
|||||||
allowErrorNodes,
|
allowErrorNodes,
|
||||||
strategy.inlineBodies,
|
strategy.inlineBodies,
|
||||||
moduleDeserializer,
|
moduleDeserializer,
|
||||||
|
useGlobalSignatures,
|
||||||
linker::handleNoModuleDeserializerFound,
|
linker::handleNoModuleDeserializerFound,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -87,7 +87,7 @@ open class DeclarationTable(globalTable: GlobalDeclarationTable) {
|
|||||||
return table.getOrPut(declaration) { builder() }
|
return table.getOrPut(declaration) { builder() }
|
||||||
}
|
}
|
||||||
|
|
||||||
fun signatureByDeclaration(declaration: IrDeclaration, compatibleMode: Boolean): IdSignature {
|
open fun signatureByDeclaration(declaration: IrDeclaration, compatibleMode: Boolean): IdSignature {
|
||||||
return computeSignatureByDeclaration(declaration, compatibleMode)
|
return computeSignatureByDeclaration(declaration, compatibleMode)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+4
@@ -155,4 +155,8 @@ class CurrentModuleWithICDeserializer(
|
|||||||
get() = delegate.moduleDependencies
|
get() = delegate.moduleDependencies
|
||||||
override val isCurrent: Boolean
|
override val isCurrent: Boolean
|
||||||
get() = delegate.isCurrent
|
get() = delegate.isCurrent
|
||||||
|
|
||||||
|
override fun fileDeserializers(): Collection<IrFileDeserializer> {
|
||||||
|
return delegate.fileDeserializers()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
+6
-3
@@ -81,7 +81,7 @@ class IrBodyDeserializer(
|
|||||||
private val fileReader: IrLibraryFile,
|
private val fileReader: IrLibraryFile,
|
||||||
private val declarationDeserializer: IrDeclarationDeserializer,
|
private val declarationDeserializer: IrDeclarationDeserializer,
|
||||||
private val statementOriginIndex: Map<String, IrStatementOrigin>,
|
private val statementOriginIndex: Map<String, IrStatementOrigin>,
|
||||||
private val allowErrorStatementOrigins: Boolean,
|
private val allowErrorStatementOrigins: Boolean, // TODO: support InlinerExpressionLocationHint
|
||||||
) {
|
) {
|
||||||
|
|
||||||
private val fileLoops = mutableMapOf<Int, IrLoop>()
|
private val fileLoops = mutableMapOf<Int, IrLoop>()
|
||||||
@@ -174,7 +174,10 @@ class IrBodyDeserializer(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun cntToReturnableBlockSymbol(upCnt: Int) = returnableBlockStack[returnableBlockStack.size - upCnt]
|
private fun cntToReturnableBlockSymbol(upCnt: Int) = if (upCnt > returnableBlockStack.size) {
|
||||||
|
// TODO: fix lowerings
|
||||||
|
IrReturnableBlockSymbolImpl()
|
||||||
|
} else returnableBlockStack[returnableBlockStack.size - upCnt]
|
||||||
|
|
||||||
private fun deserializeReturnableBlock(proto: ProtoReturnableBlock, start: Int, end: Int, type: IrType): IrReturnableBlock {
|
private fun deserializeReturnableBlock(proto: ProtoReturnableBlock, start: Int, end: Int, type: IrType): IrReturnableBlock {
|
||||||
|
|
||||||
@@ -204,7 +207,7 @@ class IrBodyDeserializer(
|
|||||||
}
|
}
|
||||||
|
|
||||||
proto.typeArgumentList.mapIndexed { i, arg ->
|
proto.typeArgumentList.mapIndexed { i, arg ->
|
||||||
access.putTypeArgument(i, declarationDeserializer.deserializeIrType(arg))
|
access.putTypeArgument(i, declarationDeserializer.deserializeNullableIrType(arg))
|
||||||
}
|
}
|
||||||
|
|
||||||
if (proto.hasDispatchReceiver()) {
|
if (proto.hasDispatchReceiver()) {
|
||||||
|
|||||||
+34
-12
@@ -70,7 +70,8 @@ class IrDeclarationDeserializer(
|
|||||||
private val skipMutableState: Boolean = false,
|
private val skipMutableState: Boolean = false,
|
||||||
additionalStatementOriginIndex: Map<String, IrStatementOrigin> = emptyMap(),
|
additionalStatementOriginIndex: Map<String, IrStatementOrigin> = emptyMap(),
|
||||||
allowErrorStatementOrigins: Boolean = false,
|
allowErrorStatementOrigins: Boolean = false,
|
||||||
private val compatibilityMode: CompatibilityMode
|
private val compatibilityMode: CompatibilityMode,
|
||||||
|
private val allowRedeclaration: Boolean = false
|
||||||
) {
|
) {
|
||||||
|
|
||||||
val bodyDeserializer = IrBodyDeserializer(builtIns, allowErrorNodes, irFactory, fileReader, this, statementOriginIndex + additionalStatementOriginIndex, allowErrorStatementOrigins)
|
val bodyDeserializer = IrBodyDeserializer(builtIns, allowErrorNodes, irFactory, fileReader, this, statementOriginIndex + additionalStatementOriginIndex, allowErrorStatementOrigins)
|
||||||
@@ -89,6 +90,8 @@ class IrDeclarationDeserializer(
|
|||||||
return ProtoType.parseFrom(readType(index), ExtensionRegistryLite.newInstance())
|
return ProtoType.parseFrom(readType(index), ExtensionRegistryLite.newInstance())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fun deserializeNullableIrType(index: Int): IrType? = if (index == -1) null else deserializeIrType(index)
|
||||||
|
|
||||||
fun deserializeIrType(index: Int): IrType {
|
fun deserializeIrType(index: Int): IrType {
|
||||||
return irTypeCache.getOrPut(index) {
|
return irTypeCache.getOrPut(index) {
|
||||||
val typeData = loadTypeProto(index)
|
val typeData = loadTypeProto(index)
|
||||||
@@ -221,7 +224,10 @@ class IrDeclarationDeserializer(
|
|||||||
coordinates.startOffset, coordinates.endOffset,
|
coordinates.startOffset, coordinates.endOffset,
|
||||||
deserializeIrDeclarationOrigin(proto.originName), proto.flags
|
deserializeIrDeclarationOrigin(proto.originName), proto.flags
|
||||||
)
|
)
|
||||||
result.annotations = deserializeAnnotations(proto.annotationList)
|
// avoid duplicate annotations for local variables
|
||||||
|
if (!allowRedeclaration || result.annotations.isEmpty()) {
|
||||||
|
result.annotations = deserializeAnnotations(proto.annotationList)
|
||||||
|
}
|
||||||
if (!skipMutableState) {
|
if (!skipMutableState) {
|
||||||
result.parent = currentParent
|
result.parent = currentParent
|
||||||
}
|
}
|
||||||
@@ -296,6 +302,8 @@ class IrDeclarationDeserializer(
|
|||||||
withDeserializedIrDeclarationBase(proto.base) { symbol, signature, startOffset, endOffset, origin, fcode ->
|
withDeserializedIrDeclarationBase(proto.base) { symbol, signature, startOffset, endOffset, origin, fcode ->
|
||||||
val flags = ClassFlags.decode(fcode)
|
val flags = ClassFlags.decode(fcode)
|
||||||
|
|
||||||
|
if (allowRedeclaration && symbol.isBound) return symbol.owner as IrClass
|
||||||
|
|
||||||
symbolTable.declareClass(signature, { symbol as IrClassSymbol }) {
|
symbolTable.declareClass(signature, { symbol as IrClassSymbol }) {
|
||||||
irFactory.createClass(
|
irFactory.createClass(
|
||||||
startOffset, endOffset, origin,
|
startOffset, endOffset, origin,
|
||||||
@@ -532,6 +540,7 @@ class IrDeclarationDeserializer(
|
|||||||
internal fun deserializeIrFunction(proto: ProtoFunction): IrSimpleFunction {
|
internal fun deserializeIrFunction(proto: ProtoFunction): IrSimpleFunction {
|
||||||
return withDeserializedIrFunctionBase(proto.base) { symbol, idSig, startOffset, endOffset, origin, fcode ->
|
return withDeserializedIrFunctionBase(proto.base) { symbol, idSig, startOffset, endOffset, origin, fcode ->
|
||||||
val flags = FunctionFlags.decode(fcode)
|
val flags = FunctionFlags.decode(fcode)
|
||||||
|
if (allowRedeclaration && symbol.isBound) return symbol.owner as IrSimpleFunction
|
||||||
symbolTable.declareSimpleFunction(idSig, { symbol as IrSimpleFunctionSymbol }) {
|
symbolTable.declareSimpleFunction(idSig, { symbol as IrSimpleFunctionSymbol }) {
|
||||||
val nameType = BinaryNameAndType.decode(proto.base.nameType)
|
val nameType = BinaryNameAndType.decode(proto.base.nameType)
|
||||||
irFactory.createFunction(
|
irFactory.createFunction(
|
||||||
@@ -560,7 +569,7 @@ class IrDeclarationDeserializer(
|
|||||||
withDeserializedIrDeclarationBase(proto.base) { symbol, _, startOffset, endOffset, origin, fcode ->
|
withDeserializedIrDeclarationBase(proto.base) { symbol, _, startOffset, endOffset, origin, fcode ->
|
||||||
val flags = LocalVariableFlags.decode(fcode)
|
val flags = LocalVariableFlags.decode(fcode)
|
||||||
val nameType = BinaryNameAndType.decode(proto.nameType)
|
val nameType = BinaryNameAndType.decode(proto.nameType)
|
||||||
IrVariableImpl(
|
(if (allowRedeclaration && symbol.isBound) symbol.owner as IrVariable else IrVariableImpl(
|
||||||
startOffset, endOffset, origin,
|
startOffset, endOffset, origin,
|
||||||
symbol as IrVariableSymbol,
|
symbol as IrVariableSymbol,
|
||||||
deserializeName(nameType.nameIndex),
|
deserializeName(nameType.nameIndex),
|
||||||
@@ -568,7 +577,7 @@ class IrDeclarationDeserializer(
|
|||||||
flags.isVar,
|
flags.isVar,
|
||||||
flags.isConst,
|
flags.isConst,
|
||||||
flags.isLateinit
|
flags.isLateinit
|
||||||
).apply {
|
)).apply {
|
||||||
if (proto.hasInitializer())
|
if (proto.hasInitializer())
|
||||||
initializer = bodyDeserializer.deserializeExpression(proto.initializer)
|
initializer = bodyDeserializer.deserializeExpression(proto.initializer)
|
||||||
}
|
}
|
||||||
@@ -622,7 +631,8 @@ class IrDeclarationDeserializer(
|
|||||||
val nameType = BinaryNameAndType.decode(proto.nameType)
|
val nameType = BinaryNameAndType.decode(proto.nameType)
|
||||||
val type = deserializeIrType(nameType.typeIndex)
|
val type = deserializeIrType(nameType.typeIndex)
|
||||||
val flags = FieldFlags.decode(fcode)
|
val flags = FieldFlags.decode(fcode)
|
||||||
symbolTable.declareField(uniqId, { symbol }) {
|
|
||||||
|
val field = if (allowRedeclaration && symbol.isBound) symbol.owner else symbolTable.declareField(uniqId, { symbol }) {
|
||||||
irFactory.createField(
|
irFactory.createField(
|
||||||
startOffset, endOffset, origin,
|
startOffset, endOffset, origin,
|
||||||
it,
|
it,
|
||||||
@@ -633,40 +643,48 @@ class IrDeclarationDeserializer(
|
|||||||
flags.isExternal || isEffectivelyExternal,
|
flags.isExternal || isEffectivelyExternal,
|
||||||
flags.isStatic,
|
flags.isStatic,
|
||||||
)
|
)
|
||||||
}.usingParent {
|
}
|
||||||
|
|
||||||
|
field.usingParent {
|
||||||
if (proto.hasInitializer()) {
|
if (proto.hasInitializer()) {
|
||||||
withInitializerGuard {
|
withInitializerGuard {
|
||||||
initializer = deserializeExpressionBody(proto.initializer)
|
initializer = deserializeExpressionBody(proto.initializer)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
field
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun deserializeIrLocalDelegatedProperty(proto: ProtoLocalDelegatedProperty): IrLocalDelegatedProperty =
|
private fun deserializeIrLocalDelegatedProperty(proto: ProtoLocalDelegatedProperty): IrLocalDelegatedProperty =
|
||||||
withDeserializedIrDeclarationBase(proto.base) { symbol, _, startOffset, endOffset, origin, fcode ->
|
withDeserializedIrDeclarationBase(proto.base) { symbol, _, startOffset, endOffset, origin, fcode ->
|
||||||
val flags = LocalVariableFlags.decode(fcode)
|
val flags = LocalVariableFlags.decode(fcode)
|
||||||
val nameAndType = BinaryNameAndType.decode(proto.nameType)
|
val nameAndType = BinaryNameAndType.decode(proto.nameType)
|
||||||
irFactory.createLocalDelegatedProperty(
|
val prop = if (allowRedeclaration && symbol.isBound) symbol.owner as IrLocalDelegatedProperty else irFactory.createLocalDelegatedProperty(
|
||||||
startOffset, endOffset, origin,
|
startOffset, endOffset, origin,
|
||||||
symbol as IrLocalDelegatedPropertySymbol,
|
symbol as IrLocalDelegatedPropertySymbol,
|
||||||
deserializeName(nameAndType.nameIndex),
|
deserializeName(nameAndType.nameIndex),
|
||||||
deserializeIrType(nameAndType.typeIndex),
|
deserializeIrType(nameAndType.typeIndex),
|
||||||
flags.isVar
|
flags.isVar
|
||||||
).apply {
|
)
|
||||||
if (!skipMutableState) {
|
|
||||||
|
if (!skipMutableState) {
|
||||||
|
prop.apply {
|
||||||
delegate = deserializeIrVariable(proto.delegate)
|
delegate = deserializeIrVariable(proto.delegate)
|
||||||
getter = deserializeIrFunction(proto.getter)
|
getter = deserializeIrFunction(proto.getter)
|
||||||
if (proto.hasSetter())
|
if (proto.hasSetter())
|
||||||
setter = deserializeIrFunction(proto.setter)
|
setter = deserializeIrFunction(proto.setter)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
prop
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun deserializeIrProperty(proto: ProtoProperty): IrProperty =
|
private fun deserializeIrProperty(proto: ProtoProperty): IrProperty =
|
||||||
withDeserializedIrDeclarationBase(proto.base) { symbol, uniqId, startOffset, endOffset, origin, fcode ->
|
withDeserializedIrDeclarationBase(proto.base) { symbol, uniqId, startOffset, endOffset, origin, fcode ->
|
||||||
require(symbol is IrPropertySymbol)
|
require(symbol is IrPropertySymbol)
|
||||||
val flags = PropertyFlags.decode(fcode)
|
val flags = PropertyFlags.decode(fcode)
|
||||||
symbolTable.declareProperty(uniqId, { symbol }) {
|
val prop = if (allowRedeclaration && symbol.isBound) symbol.owner else symbolTable.declareProperty(uniqId, { symbol }) {
|
||||||
irFactory.createProperty(
|
irFactory.createProperty(
|
||||||
startOffset, endOffset, origin,
|
startOffset, endOffset, origin,
|
||||||
it,
|
it,
|
||||||
@@ -681,8 +699,10 @@ class IrDeclarationDeserializer(
|
|||||||
flags.isExpect,
|
flags.isExpect,
|
||||||
flags.isFakeOverride
|
flags.isFakeOverride
|
||||||
)
|
)
|
||||||
}.apply {
|
}
|
||||||
if (!skipMutableState) {
|
|
||||||
|
if (!skipMutableState) {
|
||||||
|
prop.apply {
|
||||||
withExternalValue(isExternal) {
|
withExternalValue(isExternal) {
|
||||||
if (proto.hasGetter()) {
|
if (proto.hasGetter()) {
|
||||||
getter = deserializeIrFunction(proto.getter).also {
|
getter = deserializeIrFunction(proto.getter).also {
|
||||||
@@ -702,6 +722,8 @@ class IrDeclarationDeserializer(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
prop
|
||||||
}
|
}
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|||||||
+4
-2
@@ -35,7 +35,7 @@ class IrFileDeserializer(
|
|||||||
|
|
||||||
private var annotations: List<ProtoConstructorCall>? = fileProto.annotationList
|
private var annotations: List<ProtoConstructorCall>? = fileProto.annotationList
|
||||||
|
|
||||||
internal fun deserializeDeclaration(idSig: IdSignature): IrDeclaration {
|
fun deserializeDeclaration(idSig: IdSignature): IrDeclaration {
|
||||||
return declarationDeserializer.deserializeDeclaration(loadTopLevelDeclarationProto(idSig)).also {
|
return declarationDeserializer.deserializeDeclaration(loadTopLevelDeclarationProto(idSig)).also {
|
||||||
file.declarations += it
|
file.declarations += it
|
||||||
}
|
}
|
||||||
@@ -66,6 +66,7 @@ class FileDeserializationState(
|
|||||||
allowErrorNodes: Boolean,
|
allowErrorNodes: Boolean,
|
||||||
deserializeInlineFunctions: Boolean,
|
deserializeInlineFunctions: Boolean,
|
||||||
moduleDeserializer: IrModuleDeserializer,
|
moduleDeserializer: IrModuleDeserializer,
|
||||||
|
useGlobalSignatures: Boolean,
|
||||||
handleNoModuleDeserializerFound: (IdSignature, ModuleDescriptor, Collection<IrModuleDeserializer>) -> IrModuleDeserializer,
|
handleNoModuleDeserializerFound: (IdSignature, ModuleDescriptor, Collection<IrModuleDeserializer>) -> IrModuleDeserializer,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
@@ -75,6 +76,7 @@ class FileDeserializationState(
|
|||||||
fileProto.actualList,
|
fileProto.actualList,
|
||||||
::addIdSignature,
|
::addIdSignature,
|
||||||
linker::handleExpectActualMapping,
|
linker::handleExpectActualMapping,
|
||||||
|
useGlobalSignatures = useGlobalSignatures,
|
||||||
) { idSig, symbolKind ->
|
) { idSig, symbolKind ->
|
||||||
|
|
||||||
val topLevelSig = idSig.topLevelSignature()
|
val topLevelSig = idSig.topLevelSignature()
|
||||||
@@ -164,7 +166,7 @@ internal fun IrLibraryFile.deserializeDebugInfo(index: Int): String? = debugInfo
|
|||||||
internal fun IrLibraryFile.deserializeFqName(fqn: List<Int>): String =
|
internal fun IrLibraryFile.deserializeFqName(fqn: List<Int>): String =
|
||||||
fqn.joinToString(".", transform = ::deserializeString)
|
fqn.joinToString(".", transform = ::deserializeString)
|
||||||
|
|
||||||
internal fun IrLibraryFile.createFile(module: IrModuleFragment, fileProto: ProtoFile): IrFile {
|
fun IrLibraryFile.createFile(module: IrModuleFragment, fileProto: ProtoFile): IrFile {
|
||||||
val fileName = fileProto.fileEntry.name
|
val fileName = fileProto.fileEntry.name
|
||||||
val fileEntry = NaiveSourceBasedFileEntryImpl(fileName, fileProto.fileEntry.lineStartOffsetList.toIntArray())
|
val fileEntry = NaiveSourceBasedFileEntryImpl(fileName, fileProto.fileEntry.lineStartOffsetList.toIntArray())
|
||||||
val fqName = FqName(deserializeFqName(fileProto.fqNameList))
|
val fqName = FqName(deserializeFqName(fileProto.fqNameList))
|
||||||
|
|||||||
+15
-3
@@ -89,6 +89,8 @@ abstract class IrModuleDeserializer(val moduleDescriptor: ModuleDescriptor, val
|
|||||||
|
|
||||||
open val isCurrent = false
|
open val isCurrent = false
|
||||||
|
|
||||||
|
open fun fileDeserializers(): Collection<IrFileDeserializer> = error("Unsupported")
|
||||||
|
|
||||||
val compatibilityMode: CompatibilityMode get() = CompatibilityMode(libraryAbiVersion)
|
val compatibilityMode: CompatibilityMode get() = CompatibilityMode(libraryAbiVersion)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -106,9 +108,11 @@ class IrModuleDeserializerWithBuiltIns(
|
|||||||
private val irBuiltInsMap = builtIns.knownBuiltins.map {
|
private val irBuiltInsMap = builtIns.knownBuiltins.map {
|
||||||
val symbol = (it as IrSymbolOwner).symbol
|
val symbol = (it as IrSymbolOwner).symbol
|
||||||
symbol.signature to symbol
|
symbol.signature to symbol
|
||||||
}.toMap()
|
}.toMap() + additionalBuiltIns(builtIns)
|
||||||
|
|
||||||
private fun checkIsFunctionInterface(idSig: IdSignature): Boolean {
|
protected open fun additionalBuiltIns(builtIns: IrBuiltIns): Map<IdSignature, IrSymbol> = emptyMap()
|
||||||
|
|
||||||
|
protected open fun checkIsFunctionInterface(idSig: IdSignature): Boolean {
|
||||||
val publicSig = idSig.asPublic()
|
val publicSig = idSig.asPublic()
|
||||||
return publicSig != null &&
|
return publicSig != null &&
|
||||||
publicSig.packageFqName in functionalPackages &&
|
publicSig.packageFqName in functionalPackages &&
|
||||||
@@ -146,7 +150,7 @@ class IrModuleDeserializerWithBuiltIns(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun resolveFunctionalInterface(idSig: IdSignature, symbolKind: BinarySymbolData.SymbolKind): IrSymbol {
|
protected open fun resolveFunctionalInterface(idSig: IdSignature, symbolKind: BinarySymbolData.SymbolKind): IrSymbol {
|
||||||
val publicSig = idSig.asPublic() ?: error("$idSig has to be public")
|
val publicSig = idSig.asPublic() ?: error("$idSig has to be public")
|
||||||
|
|
||||||
val fqnParts = publicSig.nameSegments
|
val fqnParts = publicSig.nameSegments
|
||||||
@@ -209,6 +213,14 @@ class IrModuleDeserializerWithBuiltIns(
|
|||||||
override val moduleFragment: IrModuleFragment get() = delegate.moduleFragment
|
override val moduleFragment: IrModuleFragment get() = delegate.moduleFragment
|
||||||
override val moduleDependencies: Collection<IrModuleDeserializer> get() = delegate.moduleDependencies
|
override val moduleDependencies: Collection<IrModuleDeserializer> get() = delegate.moduleDependencies
|
||||||
override val isCurrent get() = delegate.isCurrent
|
override val isCurrent get() = delegate.isCurrent
|
||||||
|
|
||||||
|
override fun fileDeserializers(): Collection<IrFileDeserializer> {
|
||||||
|
return delegate.fileDeserializers()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun postProcess() {
|
||||||
|
delegate.postProcess()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
open class CurrentModuleDeserializer(
|
open class CurrentModuleDeserializer(
|
||||||
|
|||||||
+30
-12
@@ -12,12 +12,13 @@ import org.jetbrains.kotlin.ir.symbols.IrFileSymbol
|
|||||||
import org.jetbrains.kotlin.ir.symbols.IrPropertySymbol
|
import org.jetbrains.kotlin.ir.symbols.IrPropertySymbol
|
||||||
import org.jetbrains.kotlin.ir.symbols.IrSimpleFunctionSymbol
|
import org.jetbrains.kotlin.ir.symbols.IrSimpleFunctionSymbol
|
||||||
import org.jetbrains.kotlin.ir.symbols.IrSymbol
|
import org.jetbrains.kotlin.ir.symbols.IrSymbol
|
||||||
|
import org.jetbrains.kotlin.descriptors.ClassDescriptor
|
||||||
|
import org.jetbrains.kotlin.descriptors.ParameterDescriptor
|
||||||
|
import org.jetbrains.kotlin.ir.declarations.IrAnonymousInitializer
|
||||||
|
import org.jetbrains.kotlin.ir.declarations.IrValueParameter
|
||||||
import org.jetbrains.kotlin.ir.declarations.path
|
import org.jetbrains.kotlin.ir.declarations.path
|
||||||
import org.jetbrains.kotlin.ir.symbols.*
|
import org.jetbrains.kotlin.ir.symbols.*
|
||||||
import org.jetbrains.kotlin.ir.symbols.impl.IrAnonymousInitializerSymbolImpl
|
import org.jetbrains.kotlin.ir.symbols.impl.*
|
||||||
import org.jetbrains.kotlin.ir.symbols.impl.IrLocalDelegatedPropertySymbolImpl
|
|
||||||
import org.jetbrains.kotlin.ir.symbols.impl.IrValueParameterSymbolImpl
|
|
||||||
import org.jetbrains.kotlin.ir.symbols.impl.IrVariableSymbolImpl
|
|
||||||
import org.jetbrains.kotlin.ir.util.*
|
import org.jetbrains.kotlin.ir.util.*
|
||||||
import org.jetbrains.kotlin.protobuf.CodedInputStream
|
import org.jetbrains.kotlin.protobuf.CodedInputStream
|
||||||
import org.jetbrains.kotlin.protobuf.ExtensionRegistryLite
|
import org.jetbrains.kotlin.protobuf.ExtensionRegistryLite
|
||||||
@@ -56,7 +57,7 @@ class IrSymbolDeserializer(
|
|||||||
|
|
||||||
private fun referenceDeserializedSymbol(symbolKind: BinarySymbolData.SymbolKind, idSig: IdSignature): IrSymbol = symbolTable.run {
|
private fun referenceDeserializedSymbol(symbolKind: BinarySymbolData.SymbolKind, idSig: IdSignature): IrSymbol = symbolTable.run {
|
||||||
when (symbolKind) {
|
when (symbolKind) {
|
||||||
BinarySymbolData.SymbolKind.ANONYMOUS_INIT_SYMBOL -> IrAnonymousInitializerSymbolImpl()
|
BinarySymbolData.SymbolKind.ANONYMOUS_INIT_SYMBOL -> if (useGlobalSignatures) IrAnonymousInitializerPublicSymbolImpl(idSig) else IrAnonymousInitializerSymbolImpl()
|
||||||
BinarySymbolData.SymbolKind.CLASS_SYMBOL -> referenceClassFromLinker(idSig)
|
BinarySymbolData.SymbolKind.CLASS_SYMBOL -> referenceClassFromLinker(idSig)
|
||||||
BinarySymbolData.SymbolKind.CONSTRUCTOR_SYMBOL -> referenceConstructorFromLinker(idSig)
|
BinarySymbolData.SymbolKind.CONSTRUCTOR_SYMBOL -> referenceConstructorFromLinker(idSig)
|
||||||
BinarySymbolData.SymbolKind.TYPE_PARAMETER_SYMBOL -> referenceTypeParameterFromLinker(idSig)
|
BinarySymbolData.SymbolKind.TYPE_PARAMETER_SYMBOL -> referenceTypeParameterFromLinker(idSig)
|
||||||
@@ -67,8 +68,8 @@ class IrSymbolDeserializer(
|
|||||||
BinarySymbolData.SymbolKind.TYPEALIAS_SYMBOL -> referenceTypeAliasFromLinker(idSig)
|
BinarySymbolData.SymbolKind.TYPEALIAS_SYMBOL -> referenceTypeAliasFromLinker(idSig)
|
||||||
BinarySymbolData.SymbolKind.PROPERTY_SYMBOL -> referencePropertyFromLinker(idSig)
|
BinarySymbolData.SymbolKind.PROPERTY_SYMBOL -> referencePropertyFromLinker(idSig)
|
||||||
BinarySymbolData.SymbolKind.VARIABLE_SYMBOL -> IrVariableSymbolImpl()
|
BinarySymbolData.SymbolKind.VARIABLE_SYMBOL -> IrVariableSymbolImpl()
|
||||||
BinarySymbolData.SymbolKind.VALUE_PARAMETER_SYMBOL -> IrValueParameterSymbolImpl()
|
BinarySymbolData.SymbolKind.VALUE_PARAMETER_SYMBOL -> if (useGlobalSignatures) IrValueParameterPublicSymbolImpl(idSig) else IrValueParameterSymbolImpl()
|
||||||
BinarySymbolData.SymbolKind.RECEIVER_PARAMETER_SYMBOL -> IrValueParameterSymbolImpl()
|
BinarySymbolData.SymbolKind.RECEIVER_PARAMETER_SYMBOL -> if (useGlobalSignatures) IrValueParameterPublicSymbolImpl(idSig) else IrValueParameterSymbolImpl()
|
||||||
BinarySymbolData.SymbolKind.LOCAL_DELEGATED_PROPERTY_SYMBOL ->
|
BinarySymbolData.SymbolKind.LOCAL_DELEGATED_PROPERTY_SYMBOL ->
|
||||||
IrLocalDelegatedPropertySymbolImpl()
|
IrLocalDelegatedPropertySymbolImpl()
|
||||||
BinarySymbolData.SymbolKind.FILE_SYMBOL -> (idSig as IdSignature.FileSignature).fileSymbol
|
BinarySymbolData.SymbolKind.FILE_SYMBOL -> (idSig as IdSignature.FileSignature).fileSymbol
|
||||||
@@ -111,10 +112,14 @@ class IrSymbolDeserializer(
|
|||||||
|
|
||||||
fun parseSymbolData(code: Long): BinarySymbolData = BinarySymbolData.decode(code)
|
fun parseSymbolData(code: Long): BinarySymbolData = BinarySymbolData.decode(code)
|
||||||
|
|
||||||
|
private val symbolCache = HashMap<Long, IrSymbol>()
|
||||||
|
|
||||||
fun deserializeIrSymbol(code: Long): IrSymbol {
|
fun deserializeIrSymbol(code: Long): IrSymbol {
|
||||||
val symbolData = parseSymbolData(code)
|
return symbolCache.getOrPut(code) {
|
||||||
val signature = deserializeIdSignature(symbolData.signatureId)
|
val symbolData = parseSymbolData(code)
|
||||||
return deserializeIrSymbolData(signature, symbolData.kind)
|
val signature = deserializeIdSignature(symbolData.signatureId)
|
||||||
|
deserializeIrSymbolData(signature, symbolData.kind)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun readSignature(index: Int): CodedInputStream =
|
private fun readSignature(index: Int): CodedInputStream =
|
||||||
@@ -124,9 +129,13 @@ class IrSymbolDeserializer(
|
|||||||
return ProtoIdSignature.parseFrom(readSignature(index), ExtensionRegistryLite.newInstance())
|
return ProtoIdSignature.parseFrom(readSignature(index), ExtensionRegistryLite.newInstance())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private val signatureCache = HashMap<Int, IdSignature>()
|
||||||
|
|
||||||
fun deserializeIdSignature(index: Int): IdSignature {
|
fun deserializeIdSignature(index: Int): IdSignature {
|
||||||
val sigData = loadSignatureProto(index)
|
return signatureCache.getOrPut(index) {
|
||||||
return deserializeSignatureData(sigData)
|
val sigData = loadSignatureProto(index)
|
||||||
|
deserializeSignatureData(sigData)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* -------------------------------------------------------------- */
|
/* -------------------------------------------------------------- */
|
||||||
@@ -215,3 +224,12 @@ class IrSymbolDeserializer(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: make internal and move to deserializer
|
||||||
|
private class IrAnonymousInitializerPublicSymbolImpl(sig: IdSignature, descriptor: ClassDescriptor? = null) :
|
||||||
|
IrBindablePublicSymbolBase<ClassDescriptor, IrAnonymousInitializer>(sig, descriptor),
|
||||||
|
IrAnonymousInitializerSymbol
|
||||||
|
|
||||||
|
private class IrValueParameterPublicSymbolImpl(sig: IdSignature, descriptor: ParameterDescriptor? = null) :
|
||||||
|
IrBindablePublicSymbolBase<ParameterDescriptor, IrValueParameter>(sig, descriptor),
|
||||||
|
IrValueParameterSymbol
|
||||||
|
|||||||
+5
-8
@@ -37,12 +37,12 @@ abstract class KotlinIrLinker(
|
|||||||
) : IrDeserializer, FileLocalAwareLinker {
|
) : IrDeserializer, FileLocalAwareLinker {
|
||||||
|
|
||||||
// Kotlin-MPP related data. Consider some refactoring
|
// Kotlin-MPP related data. Consider some refactoring
|
||||||
internal val expectUniqIdToActualUniqId = mutableMapOf<IdSignature, IdSignature>()
|
val expectUniqIdToActualUniqId = mutableMapOf<IdSignature, IdSignature>()
|
||||||
internal val topLevelActualUniqItToDeserializer = mutableMapOf<IdSignature, IrModuleDeserializer>()
|
val topLevelActualUniqItToDeserializer = mutableMapOf<IdSignature, IrModuleDeserializer>()
|
||||||
internal val expectSymbols = mutableMapOf<IdSignature, IrSymbol>()
|
internal val expectSymbols = mutableMapOf<IdSignature, IrSymbol>()
|
||||||
internal val actualSymbols = mutableMapOf<IdSignature, IrSymbol>()
|
internal val actualSymbols = mutableMapOf<IdSignature, IrSymbol>()
|
||||||
|
|
||||||
internal val modulesWithReachableTopLevels = mutableSetOf<IrModuleDeserializer>()
|
val modulesWithReachableTopLevels = mutableSetOf<IrModuleDeserializer>()
|
||||||
|
|
||||||
protected val deserializersForModules = mutableMapOf<String, IrModuleDeserializer>()
|
protected val deserializersForModules = mutableMapOf<String, IrModuleDeserializer>()
|
||||||
|
|
||||||
@@ -51,7 +51,7 @@ abstract class KotlinIrLinker(
|
|||||||
abstract val translationPluginContext: TranslationPluginContext?
|
abstract val translationPluginContext: TranslationPluginContext?
|
||||||
|
|
||||||
internal val triedToDeserializeDeclarationForSymbol = mutableSetOf<IrSymbol>()
|
internal val triedToDeserializeDeclarationForSymbol = mutableSetOf<IrSymbol>()
|
||||||
internal val deserializedSymbols = mutableSetOf<IrSymbol>()
|
val deserializedSymbols = mutableSetOf<IrSymbol>()
|
||||||
|
|
||||||
private lateinit var linkerExtensions: Collection<IrDeserializer.IrLinkerExtension>
|
private lateinit var linkerExtensions: Collection<IrDeserializer.IrLinkerExtension>
|
||||||
|
|
||||||
@@ -101,7 +101,6 @@ abstract class KotlinIrLinker(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@OptIn(ObsoleteDescriptorBasedAPI::class)
|
|
||||||
private fun findDeserializedDeclarationForSymbol(symbol: IrSymbol): DeclarationDescriptor? {
|
private fun findDeserializedDeclarationForSymbol(symbol: IrSymbol): DeclarationDescriptor? {
|
||||||
|
|
||||||
if (symbol in triedToDeserializeDeclarationForSymbol || symbol in deserializedSymbols) {
|
if (symbol in triedToDeserializeDeclarationForSymbol || symbol in deserializedSymbols) {
|
||||||
@@ -123,7 +122,6 @@ abstract class KotlinIrLinker(
|
|||||||
|
|
||||||
protected open fun platformSpecificSymbol(symbol: IrSymbol): Boolean = false
|
protected open fun platformSpecificSymbol(symbol: IrSymbol): Boolean = false
|
||||||
|
|
||||||
@OptIn(ObsoleteDescriptorBasedAPI::class)
|
|
||||||
private fun tryResolveCustomDeclaration(symbol: IrSymbol): IrDeclaration? {
|
private fun tryResolveCustomDeclaration(symbol: IrSymbol): IrDeclaration? {
|
||||||
if (!symbol.hasDescriptor) return null
|
if (!symbol.hasDescriptor) return null
|
||||||
|
|
||||||
@@ -145,7 +143,6 @@ abstract class KotlinIrLinker(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@OptIn(ObsoleteDescriptorBasedAPI::class)
|
|
||||||
override fun getDeclaration(symbol: IrSymbol): IrDeclaration? {
|
override fun getDeclaration(symbol: IrSymbol): IrDeclaration? {
|
||||||
|
|
||||||
if (!symbol.isPublicApi) {
|
if (!symbol.isPublicApi) {
|
||||||
@@ -308,7 +305,7 @@ abstract class KotlinIrLinker(
|
|||||||
return deserializerForModule.moduleFragment
|
return deserializerForModule.moduleFragment
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun maybeWrapWithBuiltInAndInit(
|
protected open fun maybeWrapWithBuiltInAndInit(
|
||||||
moduleDescriptor: ModuleDescriptor,
|
moduleDescriptor: ModuleDescriptor,
|
||||||
moduleDeserializer: IrModuleDeserializer
|
moduleDeserializer: IrModuleDeserializer
|
||||||
): IrModuleDeserializer =
|
): IrModuleDeserializer =
|
||||||
|
|||||||
+2
-2
@@ -14,8 +14,8 @@ value class BinaryCoordinates(private val decoded: BinaryLattice) {
|
|||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun encode(startOffset: Int, endOffset: Int): Long {
|
fun encode(startOffset: Int, endOffset: Int): Long {
|
||||||
assert(startOffset <= endOffset)
|
// assert(startOffset <= endOffset)
|
||||||
return BinaryLattice.encode(startOffset, endOffset - startOffset)
|
return BinaryLattice.encode(startOffset, Math.abs(endOffset - startOffset))
|
||||||
}
|
}
|
||||||
|
|
||||||
fun decode(code: Long) = BinaryCoordinates(BinaryLattice.decode(code)).also { assert(it.startOffset <= it.endOffset) }
|
fun decode(code: Long) = BinaryCoordinates(BinaryLattice.decode(code)).also { assert(it.startOffset <= it.endOffset) }
|
||||||
|
|||||||
+17
-21
@@ -177,13 +177,13 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
public static final int DELEGATE_FIELD_NUMBER = 3;
|
public static final int DELEGATE_FIELD_NUMBER = 3;
|
||||||
private org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate_;
|
private org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate_;
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasDelegate() {
|
public boolean hasDelegate() {
|
||||||
return ((bitField0_ & 0x00000004) == 0x00000004);
|
return ((bitField0_ & 0x00000004) == 0x00000004);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate() {
|
||||||
return delegate_;
|
return delegate_;
|
||||||
@@ -240,17 +240,15 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
memoizedIsInitialized = 0;
|
memoizedIsInitialized = 0;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!hasDelegate()) {
|
|
||||||
memoizedIsInitialized = 0;
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (!getBase().isInitialized()) {
|
if (!getBase().isInitialized()) {
|
||||||
memoizedIsInitialized = 0;
|
memoizedIsInitialized = 0;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!getDelegate().isInitialized()) {
|
if (hasDelegate()) {
|
||||||
memoizedIsInitialized = 0;
|
if (!getDelegate().isInitialized()) {
|
||||||
return false;
|
memoizedIsInitialized = 0;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (hasGetter()) {
|
if (hasGetter()) {
|
||||||
if (!getGetter().isInitialized()) {
|
if (!getGetter().isInitialized()) {
|
||||||
@@ -497,17 +495,15 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!hasDelegate()) {
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (!getBase().isInitialized()) {
|
if (!getBase().isInitialized()) {
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!getDelegate().isInitialized()) {
|
if (hasDelegate()) {
|
||||||
|
if (!getDelegate().isInitialized()) {
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (hasGetter()) {
|
if (hasGetter()) {
|
||||||
if (!getGetter().isInitialized()) {
|
if (!getGetter().isInitialized()) {
|
||||||
@@ -637,19 +633,19 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
|
|
||||||
private org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.getDefaultInstance();
|
private org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.getDefaultInstance();
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasDelegate() {
|
public boolean hasDelegate() {
|
||||||
return ((bitField0_ & 0x00000004) == 0x00000004);
|
return ((bitField0_ & 0x00000004) == 0x00000004);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate() {
|
||||||
return delegate_;
|
return delegate_;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setDelegate(org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable value) {
|
public Builder setDelegate(org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable value) {
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
@@ -661,7 +657,7 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setDelegate(
|
public Builder setDelegate(
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.Builder builderForValue) {
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.Builder builderForValue) {
|
||||||
@@ -671,7 +667,7 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public Builder mergeDelegate(org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable value) {
|
public Builder mergeDelegate(org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable value) {
|
||||||
if (((bitField0_ & 0x00000004) == 0x00000004) &&
|
if (((bitField0_ & 0x00000004) == 0x00000004) &&
|
||||||
@@ -686,7 +682,7 @@ public final class IrLocalDelegatedProperty extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearDelegate() {
|
public Builder clearDelegate() {
|
||||||
delegate_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.getDefaultInstance();
|
delegate_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable.getDefaultInstance();
|
||||||
|
|||||||
+2
-2
@@ -26,11 +26,11 @@ public interface IrLocalDelegatedPropertyOrBuilder extends
|
|||||||
long getNameType();
|
long getNameType();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasDelegate();
|
boolean hasDelegate();
|
||||||
/**
|
/**
|
||||||
* <code>required .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable delegate = 3;</code>
|
||||||
*/
|
*/
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate();
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrVariable getDelegate();
|
||||||
|
|
||||||
|
|||||||
+84
-84
@@ -514,9 +514,9 @@ public final class IrOperation extends
|
|||||||
operationCase_ = 35;
|
operationCase_ = 35;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 290: {
|
case 1090: {
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.Builder subBuilder = null;
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.Builder subBuilder = null;
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_).toBuilder();
|
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_).toBuilder();
|
||||||
}
|
}
|
||||||
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.PARSER, extensionRegistry);
|
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.PARSER, extensionRegistry);
|
||||||
@@ -524,12 +524,12 @@ public final class IrOperation extends
|
|||||||
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
||||||
operation_ = subBuilder.buildPartial();
|
operation_ = subBuilder.buildPartial();
|
||||||
}
|
}
|
||||||
operationCase_ = 36;
|
operationCase_ = 136;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 298: {
|
case 1098: {
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.Builder subBuilder = null;
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.Builder subBuilder = null;
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_).toBuilder();
|
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_).toBuilder();
|
||||||
}
|
}
|
||||||
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.PARSER, extensionRegistry);
|
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.PARSER, extensionRegistry);
|
||||||
@@ -537,12 +537,12 @@ public final class IrOperation extends
|
|||||||
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
||||||
operation_ = subBuilder.buildPartial();
|
operation_ = subBuilder.buildPartial();
|
||||||
}
|
}
|
||||||
operationCase_ = 37;
|
operationCase_ = 137;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 306: {
|
case 1106: {
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.Builder subBuilder = null;
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.Builder subBuilder = null;
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_).toBuilder();
|
subBuilder = ((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_).toBuilder();
|
||||||
}
|
}
|
||||||
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.PARSER, extensionRegistry);
|
operation_ = input.readMessage(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.PARSER, extensionRegistry);
|
||||||
@@ -550,7 +550,7 @@ public final class IrOperation extends
|
|||||||
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
subBuilder.mergeFrom((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
||||||
operation_ = subBuilder.buildPartial();
|
operation_ = subBuilder.buildPartial();
|
||||||
}
|
}
|
||||||
operationCase_ = 38;
|
operationCase_ = 138;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -627,9 +627,9 @@ public final class IrOperation extends
|
|||||||
FUNCTION_EXPRESSION(33),
|
FUNCTION_EXPRESSION(33),
|
||||||
ERROR_EXPRESSION(34),
|
ERROR_EXPRESSION(34),
|
||||||
ERROR_CALL_EXPRESSION(35),
|
ERROR_CALL_EXPRESSION(35),
|
||||||
RAW_FUNCTION_REFERENCE(36),
|
RAW_FUNCTION_REFERENCE(136),
|
||||||
RETURNABLE_BLOCK(37),
|
RETURNABLE_BLOCK(137),
|
||||||
RETURNABLE_BLOCK_RETURN(38),
|
RETURNABLE_BLOCK_RETURN(138),
|
||||||
OPERATION_NOT_SET(0);
|
OPERATION_NOT_SET(0);
|
||||||
private int value = 0;
|
private int value = 0;
|
||||||
private OperationCase(int value) {
|
private OperationCase(int value) {
|
||||||
@@ -672,9 +672,9 @@ public final class IrOperation extends
|
|||||||
case 33: return FUNCTION_EXPRESSION;
|
case 33: return FUNCTION_EXPRESSION;
|
||||||
case 34: return ERROR_EXPRESSION;
|
case 34: return ERROR_EXPRESSION;
|
||||||
case 35: return ERROR_CALL_EXPRESSION;
|
case 35: return ERROR_CALL_EXPRESSION;
|
||||||
case 36: return RAW_FUNCTION_REFERENCE;
|
case 136: return RAW_FUNCTION_REFERENCE;
|
||||||
case 37: return RETURNABLE_BLOCK;
|
case 137: return RETURNABLE_BLOCK;
|
||||||
case 38: return RETURNABLE_BLOCK_RETURN;
|
case 138: return RETURNABLE_BLOCK_RETURN;
|
||||||
case 0: return OPERATION_NOT_SET;
|
case 0: return OPERATION_NOT_SET;
|
||||||
default: throw new java.lang.IllegalArgumentException(
|
default: throw new java.lang.IllegalArgumentException(
|
||||||
"Value is undefined for this oneof enum.");
|
"Value is undefined for this oneof enum.");
|
||||||
@@ -1294,52 +1294,52 @@ public final class IrOperation extends
|
|||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression.getDefaultInstance();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final int RAW_FUNCTION_REFERENCE_FIELD_NUMBER = 36;
|
public static final int RAW_FUNCTION_REFERENCE_FIELD_NUMBER = 136;
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasRawFunctionReference() {
|
public boolean hasRawFunctionReference() {
|
||||||
return operationCase_ == 36;
|
return operationCase_ == 136;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference() {
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final int RETURNABLE_BLOCK_FIELD_NUMBER = 37;
|
public static final int RETURNABLE_BLOCK_FIELD_NUMBER = 137;
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasReturnableBlock() {
|
public boolean hasReturnableBlock() {
|
||||||
return operationCase_ == 37;
|
return operationCase_ == 137;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock() {
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final int RETURNABLE_BLOCK_RETURN_FIELD_NUMBER = 38;
|
public static final int RETURNABLE_BLOCK_RETURN_FIELD_NUMBER = 138;
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasReturnableBlockReturn() {
|
public boolean hasReturnableBlockReturn() {
|
||||||
return operationCase_ == 38;
|
return operationCase_ == 138;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn() {
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance();
|
||||||
@@ -1687,14 +1687,14 @@ public final class IrOperation extends
|
|||||||
if (operationCase_ == 35) {
|
if (operationCase_ == 35) {
|
||||||
output.writeMessage(35, (org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression) operation_);
|
output.writeMessage(35, (org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
output.writeMessage(36, (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
output.writeMessage(136, (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
output.writeMessage(37, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
output.writeMessage(137, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
output.writeMessage(38, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
output.writeMessage(138, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
||||||
}
|
}
|
||||||
output.writeRawBytes(unknownFields);
|
output.writeRawBytes(unknownFields);
|
||||||
}
|
}
|
||||||
@@ -1845,17 +1845,17 @@ public final class IrOperation extends
|
|||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeMessageSize(35, (org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression) operation_);
|
.computeMessageSize(35, (org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeMessageSize(36, (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
.computeMessageSize(136, (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeMessageSize(37, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
.computeMessageSize(137, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_);
|
||||||
}
|
}
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeMessageSize(38, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
.computeMessageSize(138, (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_);
|
||||||
}
|
}
|
||||||
size += unknownFields.size();
|
size += unknownFields.size();
|
||||||
memoizedSerializedSize = size;
|
memoizedSerializedSize = size;
|
||||||
@@ -2088,13 +2088,13 @@ public final class IrOperation extends
|
|||||||
if (operationCase_ == 35) {
|
if (operationCase_ == 35) {
|
||||||
result.operation_ = operation_;
|
result.operation_ = operation_;
|
||||||
}
|
}
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
result.operation_ = operation_;
|
result.operation_ = operation_;
|
||||||
}
|
}
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
result.operation_ = operation_;
|
result.operation_ = operation_;
|
||||||
}
|
}
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
result.operation_ = operation_;
|
result.operation_ = operation_;
|
||||||
}
|
}
|
||||||
result.bitField0_ = to_bitField0_;
|
result.bitField0_ = to_bitField0_;
|
||||||
@@ -4792,22 +4792,22 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasRawFunctionReference() {
|
public boolean hasRawFunctionReference() {
|
||||||
return operationCase_ == 36;
|
return operationCase_ == 136;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference() {
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance();
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setRawFunctionReference(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference value) {
|
public Builder setRawFunctionReference(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference value) {
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
@@ -4815,24 +4815,24 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
operation_ = value;
|
operation_ = value;
|
||||||
|
|
||||||
operationCase_ = 36;
|
operationCase_ = 136;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setRawFunctionReference(
|
public Builder setRawFunctionReference(
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.Builder builderForValue) {
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.Builder builderForValue) {
|
||||||
operation_ = builderForValue.build();
|
operation_ = builderForValue.build();
|
||||||
|
|
||||||
operationCase_ = 36;
|
operationCase_ = 136;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public Builder mergeRawFunctionReference(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference value) {
|
public Builder mergeRawFunctionReference(org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference value) {
|
||||||
if (operationCase_ == 36 &&
|
if (operationCase_ == 136 &&
|
||||||
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance()) {
|
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.getDefaultInstance()) {
|
||||||
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_)
|
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference) operation_)
|
||||||
.mergeFrom(value).buildPartial();
|
.mergeFrom(value).buildPartial();
|
||||||
@@ -4840,14 +4840,14 @@ public final class IrOperation extends
|
|||||||
operation_ = value;
|
operation_ = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
operationCase_ = 36;
|
operationCase_ = 136;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearRawFunctionReference() {
|
public Builder clearRawFunctionReference() {
|
||||||
if (operationCase_ == 36) {
|
if (operationCase_ == 136) {
|
||||||
operationCase_ = 0;
|
operationCase_ = 0;
|
||||||
operation_ = null;
|
operation_ = null;
|
||||||
|
|
||||||
@@ -4856,22 +4856,22 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasReturnableBlock() {
|
public boolean hasReturnableBlock() {
|
||||||
return operationCase_ == 37;
|
return operationCase_ == 137;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock() {
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance();
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setReturnableBlock(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock value) {
|
public Builder setReturnableBlock(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock value) {
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
@@ -4879,24 +4879,24 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
operation_ = value;
|
operation_ = value;
|
||||||
|
|
||||||
operationCase_ = 37;
|
operationCase_ = 137;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setReturnableBlock(
|
public Builder setReturnableBlock(
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.Builder builderForValue) {
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.Builder builderForValue) {
|
||||||
operation_ = builderForValue.build();
|
operation_ = builderForValue.build();
|
||||||
|
|
||||||
operationCase_ = 37;
|
operationCase_ = 137;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public Builder mergeReturnableBlock(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock value) {
|
public Builder mergeReturnableBlock(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock value) {
|
||||||
if (operationCase_ == 37 &&
|
if (operationCase_ == 137 &&
|
||||||
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance()) {
|
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.getDefaultInstance()) {
|
||||||
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_)
|
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock) operation_)
|
||||||
.mergeFrom(value).buildPartial();
|
.mergeFrom(value).buildPartial();
|
||||||
@@ -4904,14 +4904,14 @@ public final class IrOperation extends
|
|||||||
operation_ = value;
|
operation_ = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
operationCase_ = 37;
|
operationCase_ = 137;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearReturnableBlock() {
|
public Builder clearReturnableBlock() {
|
||||||
if (operationCase_ == 37) {
|
if (operationCase_ == 137) {
|
||||||
operationCase_ = 0;
|
operationCase_ = 0;
|
||||||
operation_ = null;
|
operation_ = null;
|
||||||
|
|
||||||
@@ -4920,22 +4920,22 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasReturnableBlockReturn() {
|
public boolean hasReturnableBlockReturn() {
|
||||||
return operationCase_ == 38;
|
return operationCase_ == 138;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn() {
|
public org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn() {
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_;
|
return (org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_;
|
||||||
}
|
}
|
||||||
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance();
|
return org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance();
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setReturnableBlockReturn(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn value) {
|
public Builder setReturnableBlockReturn(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn value) {
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
@@ -4943,24 +4943,24 @@ public final class IrOperation extends
|
|||||||
}
|
}
|
||||||
operation_ = value;
|
operation_ = value;
|
||||||
|
|
||||||
operationCase_ = 38;
|
operationCase_ = 138;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setReturnableBlockReturn(
|
public Builder setReturnableBlockReturn(
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.Builder builderForValue) {
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.Builder builderForValue) {
|
||||||
operation_ = builderForValue.build();
|
operation_ = builderForValue.build();
|
||||||
|
|
||||||
operationCase_ = 38;
|
operationCase_ = 138;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public Builder mergeReturnableBlockReturn(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn value) {
|
public Builder mergeReturnableBlockReturn(org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn value) {
|
||||||
if (operationCase_ == 38 &&
|
if (operationCase_ == 138 &&
|
||||||
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance()) {
|
operation_ != org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.getDefaultInstance()) {
|
||||||
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_)
|
operation_ = org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn.newBuilder((org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn) operation_)
|
||||||
.mergeFrom(value).buildPartial();
|
.mergeFrom(value).buildPartial();
|
||||||
@@ -4968,14 +4968,14 @@ public final class IrOperation extends
|
|||||||
operation_ = value;
|
operation_ = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
operationCase_ = 38;
|
operationCase_ = 138;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearReturnableBlockReturn() {
|
public Builder clearReturnableBlockReturn() {
|
||||||
if (operationCase_ == 38) {
|
if (operationCase_ == 138) {
|
||||||
operationCase_ = 0;
|
operationCase_ = 0;
|
||||||
operation_ = null;
|
operation_ = null;
|
||||||
|
|
||||||
|
|||||||
+6
-6
@@ -331,29 +331,29 @@ public interface IrOperationOrBuilder extends
|
|||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression getErrorCallExpression();
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrErrorCallExpression getErrorCallExpression();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasRawFunctionReference();
|
boolean hasRawFunctionReference();
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 36;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference raw_function_reference = 136;</code>
|
||||||
*/
|
*/
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference();
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrRawFunctionReference getRawFunctionReference();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasReturnableBlock();
|
boolean hasReturnableBlock();
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 37;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock returnable_block = 137;</code>
|
||||||
*/
|
*/
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock();
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlock getReturnableBlock();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasReturnableBlockReturn();
|
boolean hasReturnableBlockReturn();
|
||||||
/**
|
/**
|
||||||
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 38;</code>
|
* <code>optional .org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn returnable_block_return = 138;</code>
|
||||||
*/
|
*/
|
||||||
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn();
|
org.jetbrains.kotlin.backend.common.serialization.proto.IrReturnableBlockReturn getReturnableBlockReturn();
|
||||||
}
|
}
|
||||||
+20
-20
@@ -92,12 +92,12 @@ public final class IrTypeParameter extends
|
|||||||
input.popLimit(limit);
|
input.popLimit(limit);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 32: {
|
case 832: {
|
||||||
bitField0_ |= 0x00000004;
|
bitField0_ |= 0x00000004;
|
||||||
index_ = input.readInt32();
|
index_ = input.readInt32();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 40: {
|
case 840: {
|
||||||
bitField0_ |= 0x00000008;
|
bitField0_ |= 0x00000008;
|
||||||
isGlobal_ = input.readBool();
|
isGlobal_ = input.readBool();
|
||||||
break;
|
break;
|
||||||
@@ -192,31 +192,31 @@ public final class IrTypeParameter extends
|
|||||||
}
|
}
|
||||||
private int superTypeMemoizedSerializedSize = -1;
|
private int superTypeMemoizedSerializedSize = -1;
|
||||||
|
|
||||||
public static final int INDEX_FIELD_NUMBER = 4;
|
public static final int INDEX_FIELD_NUMBER = 104;
|
||||||
private int index_;
|
private int index_;
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIndex() {
|
public boolean hasIndex() {
|
||||||
return ((bitField0_ & 0x00000004) == 0x00000004);
|
return ((bitField0_ & 0x00000004) == 0x00000004);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public int getIndex() {
|
public int getIndex() {
|
||||||
return index_;
|
return index_;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final int ISGLOBAL_FIELD_NUMBER = 5;
|
public static final int ISGLOBAL_FIELD_NUMBER = 105;
|
||||||
private boolean isGlobal_;
|
private boolean isGlobal_;
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIsGlobal() {
|
public boolean hasIsGlobal() {
|
||||||
return ((bitField0_ & 0x00000008) == 0x00000008);
|
return ((bitField0_ & 0x00000008) == 0x00000008);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean getIsGlobal() {
|
public boolean getIsGlobal() {
|
||||||
return isGlobal_;
|
return isGlobal_;
|
||||||
@@ -268,10 +268,10 @@ public final class IrTypeParameter extends
|
|||||||
output.writeInt32NoTag(superType_.get(i));
|
output.writeInt32NoTag(superType_.get(i));
|
||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
||||||
output.writeInt32(4, index_);
|
output.writeInt32(104, index_);
|
||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000008) == 0x00000008)) {
|
if (((bitField0_ & 0x00000008) == 0x00000008)) {
|
||||||
output.writeBool(5, isGlobal_);
|
output.writeBool(105, isGlobal_);
|
||||||
}
|
}
|
||||||
output.writeRawBytes(unknownFields);
|
output.writeRawBytes(unknownFields);
|
||||||
}
|
}
|
||||||
@@ -306,11 +306,11 @@ public final class IrTypeParameter extends
|
|||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeInt32Size(4, index_);
|
.computeInt32Size(104, index_);
|
||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000008) == 0x00000008)) {
|
if (((bitField0_ & 0x00000008) == 0x00000008)) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeBoolSize(5, isGlobal_);
|
.computeBoolSize(105, isGlobal_);
|
||||||
}
|
}
|
||||||
size += unknownFields.size();
|
size += unknownFields.size();
|
||||||
memoizedSerializedSize = size;
|
memoizedSerializedSize = size;
|
||||||
@@ -688,19 +688,19 @@ public final class IrTypeParameter extends
|
|||||||
|
|
||||||
private int index_ ;
|
private int index_ ;
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIndex() {
|
public boolean hasIndex() {
|
||||||
return ((bitField0_ & 0x00000008) == 0x00000008);
|
return ((bitField0_ & 0x00000008) == 0x00000008);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public int getIndex() {
|
public int getIndex() {
|
||||||
return index_;
|
return index_;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setIndex(int value) {
|
public Builder setIndex(int value) {
|
||||||
bitField0_ |= 0x00000008;
|
bitField0_ |= 0x00000008;
|
||||||
@@ -709,7 +709,7 @@ public final class IrTypeParameter extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearIndex() {
|
public Builder clearIndex() {
|
||||||
bitField0_ = (bitField0_ & ~0x00000008);
|
bitField0_ = (bitField0_ & ~0x00000008);
|
||||||
@@ -720,19 +720,19 @@ public final class IrTypeParameter extends
|
|||||||
|
|
||||||
private boolean isGlobal_ ;
|
private boolean isGlobal_ ;
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIsGlobal() {
|
public boolean hasIsGlobal() {
|
||||||
return ((bitField0_ & 0x00000010) == 0x00000010);
|
return ((bitField0_ & 0x00000010) == 0x00000010);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean getIsGlobal() {
|
public boolean getIsGlobal() {
|
||||||
return isGlobal_;
|
return isGlobal_;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setIsGlobal(boolean value) {
|
public Builder setIsGlobal(boolean value) {
|
||||||
bitField0_ |= 0x00000010;
|
bitField0_ |= 0x00000010;
|
||||||
@@ -741,7 +741,7 @@ public final class IrTypeParameter extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearIsGlobal() {
|
public Builder clearIsGlobal() {
|
||||||
bitField0_ = (bitField0_ & ~0x00000010);
|
bitField0_ = (bitField0_ & ~0x00000010);
|
||||||
|
|||||||
+4
-4
@@ -39,20 +39,20 @@ public interface IrTypeParameterOrBuilder extends
|
|||||||
int getSuperType(int index);
|
int getSuperType(int index);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasIndex();
|
boolean hasIndex();
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 4;</code>
|
* <code>optional int32 index = 104;</code>
|
||||||
*/
|
*/
|
||||||
int getIndex();
|
int getIndex();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasIsGlobal();
|
boolean hasIsGlobal();
|
||||||
/**
|
/**
|
||||||
* <code>optional bool isGlobal = 5;</code>
|
* <code>optional bool isGlobal = 105;</code>
|
||||||
*/
|
*/
|
||||||
boolean getIsGlobal();
|
boolean getIsGlobal();
|
||||||
}
|
}
|
||||||
+10
-10
@@ -81,7 +81,7 @@ public final class IrValueParameter extends
|
|||||||
defaultValue_ = input.readInt32();
|
defaultValue_ = input.readInt32();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 40: {
|
case 840: {
|
||||||
bitField0_ |= 0x00000010;
|
bitField0_ |= 0x00000010;
|
||||||
index_ = input.readInt32();
|
index_ = input.readInt32();
|
||||||
break;
|
break;
|
||||||
@@ -180,16 +180,16 @@ public final class IrValueParameter extends
|
|||||||
return defaultValue_;
|
return defaultValue_;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final int INDEX_FIELD_NUMBER = 5;
|
public static final int INDEX_FIELD_NUMBER = 105;
|
||||||
private int index_;
|
private int index_;
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIndex() {
|
public boolean hasIndex() {
|
||||||
return ((bitField0_ & 0x00000010) == 0x00000010);
|
return ((bitField0_ & 0x00000010) == 0x00000010);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public int getIndex() {
|
public int getIndex() {
|
||||||
return index_;
|
return index_;
|
||||||
@@ -240,7 +240,7 @@ public final class IrValueParameter extends
|
|||||||
output.writeInt32(4, defaultValue_);
|
output.writeInt32(4, defaultValue_);
|
||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000010) == 0x00000010)) {
|
if (((bitField0_ & 0x00000010) == 0x00000010)) {
|
||||||
output.writeInt32(5, index_);
|
output.writeInt32(105, index_);
|
||||||
}
|
}
|
||||||
output.writeRawBytes(unknownFields);
|
output.writeRawBytes(unknownFields);
|
||||||
}
|
}
|
||||||
@@ -269,7 +269,7 @@ public final class IrValueParameter extends
|
|||||||
}
|
}
|
||||||
if (((bitField0_ & 0x00000010) == 0x00000010)) {
|
if (((bitField0_ & 0x00000010) == 0x00000010)) {
|
||||||
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
size += org.jetbrains.kotlin.protobuf.CodedOutputStream
|
||||||
.computeInt32Size(5, index_);
|
.computeInt32Size(105, index_);
|
||||||
}
|
}
|
||||||
size += unknownFields.size();
|
size += unknownFields.size();
|
||||||
memoizedSerializedSize = size;
|
memoizedSerializedSize = size;
|
||||||
@@ -637,19 +637,19 @@ public final class IrValueParameter extends
|
|||||||
|
|
||||||
private int index_ ;
|
private int index_ ;
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public boolean hasIndex() {
|
public boolean hasIndex() {
|
||||||
return ((bitField0_ & 0x00000010) == 0x00000010);
|
return ((bitField0_ & 0x00000010) == 0x00000010);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public int getIndex() {
|
public int getIndex() {
|
||||||
return index_;
|
return index_;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public Builder setIndex(int value) {
|
public Builder setIndex(int value) {
|
||||||
bitField0_ |= 0x00000010;
|
bitField0_ |= 0x00000010;
|
||||||
@@ -658,7 +658,7 @@ public final class IrValueParameter extends
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
public Builder clearIndex() {
|
public Builder clearIndex() {
|
||||||
bitField0_ = (bitField0_ & ~0x00000010);
|
bitField0_ = (bitField0_ & ~0x00000010);
|
||||||
|
|||||||
+2
-2
@@ -44,11 +44,11 @@ public interface IrValueParameterOrBuilder extends
|
|||||||
int getDefaultValue();
|
int getDefaultValue();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
boolean hasIndex();
|
boolean hasIndex();
|
||||||
/**
|
/**
|
||||||
* <code>optional int32 index = 5;</code>
|
* <code>optional int32 index = 105;</code>
|
||||||
*/
|
*/
|
||||||
int getIndex();
|
int getIndex();
|
||||||
}
|
}
|
||||||
+22
-11
@@ -18,6 +18,7 @@ import org.jetbrains.kotlin.ir.util.IdSignature
|
|||||||
import org.jetbrains.kotlin.ir.util.KotlinMangler
|
import org.jetbrains.kotlin.ir.util.KotlinMangler
|
||||||
import org.jetbrains.kotlin.ir.util.isFacadeClass
|
import org.jetbrains.kotlin.ir.util.isFacadeClass
|
||||||
import org.jetbrains.kotlin.ir.util.render
|
import org.jetbrains.kotlin.ir.util.render
|
||||||
|
import org.jetbrains.kotlin.ir.util.*
|
||||||
import org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid
|
import org.jetbrains.kotlin.ir.visitors.IrElementVisitorVoid
|
||||||
import org.jetbrains.kotlin.ir.visitors.acceptVoid
|
import org.jetbrains.kotlin.ir.visitors.acceptVoid
|
||||||
|
|
||||||
@@ -203,8 +204,6 @@ class PublicIdSignatureComputer(val mangler: KotlinMangler.IrMangler) : IdSignat
|
|||||||
open class IdSignatureSerializer(
|
open class IdSignatureSerializer(
|
||||||
private val publicSignatureBuilder: PublicIdSignatureComputer,
|
private val publicSignatureBuilder: PublicIdSignatureComputer,
|
||||||
private val table: DeclarationTable,
|
private val table: DeclarationTable,
|
||||||
localIndexOffset: Long = 0,
|
|
||||||
scopeIndexOffset: Int = 0,
|
|
||||||
) : IdSignatureComputer {
|
) : IdSignatureComputer {
|
||||||
|
|
||||||
private val mangler: KotlinMangler.IrMangler = publicSignatureBuilder.mangler
|
private val mangler: KotlinMangler.IrMangler = publicSignatureBuilder.mangler
|
||||||
@@ -219,8 +218,8 @@ open class IdSignatureSerializer(
|
|||||||
} else composeFileLocalIdSignature(declaration, compatibleMode)
|
} else composeFileLocalIdSignature(declaration, compatibleMode)
|
||||||
}
|
}
|
||||||
|
|
||||||
private var localIndex: Long = localIndexOffset
|
protected var localIndex: Long = 0
|
||||||
private var scopeIndex: Int = scopeIndexOffset
|
protected var scopeIndex: Int = 0
|
||||||
|
|
||||||
override fun inFile(file: IrFileSymbol?, block: () -> Unit) {
|
override fun inFile(file: IrFileSymbol?, block: () -> Unit) {
|
||||||
publicSignatureBuilder.inFile(file, block)
|
publicSignatureBuilder.inFile(file, block)
|
||||||
@@ -238,19 +237,19 @@ open class IdSignatureSerializer(
|
|||||||
|
|
||||||
return table.privateDeclarationSignature(declaration, compatibleMode) {
|
return table.privateDeclarationSignature(declaration, compatibleMode) {
|
||||||
when (declaration) {
|
when (declaration) {
|
||||||
is IrValueDeclaration -> IdSignature.ScopeLocalDeclaration(scopeIndex++, declaration.name.asString())
|
is IrValueDeclaration -> declaration.createScopeLocalSignature(scopeIndex++, declaration.name.asString())
|
||||||
is IrAnonymousInitializer -> IdSignature.ScopeLocalDeclaration(scopeIndex++, "ANON INIT")
|
is IrAnonymousInitializer -> declaration.createScopeLocalSignature(scopeIndex++, "ANON INIT")
|
||||||
is IrLocalDelegatedProperty -> IdSignature.ScopeLocalDeclaration(scopeIndex++, declaration.name.asString())
|
is IrLocalDelegatedProperty -> declaration.createScopeLocalSignature(scopeIndex++, declaration.name.asString())
|
||||||
is IrField -> {
|
is IrField -> {
|
||||||
val p = declaration.correspondingPropertySymbol?.let { composeSignatureForDeclaration(it.owner, true) }
|
val p = declaration.correspondingPropertySymbol?.let { composeSignatureForDeclaration(it.owner, true) }
|
||||||
?: composeContainerIdSignature(declaration.parent, compatibleMode)
|
?: composeContainerIdSignature(declaration.parent, compatibleMode)
|
||||||
IdSignature.FileLocalSignature(p, ++localIndex)
|
declaration.createFileLocalSignature(p, ++localIndex)
|
||||||
}
|
}
|
||||||
is IrSimpleFunction -> {
|
is IrSimpleFunction -> {
|
||||||
val parent = declaration.parent
|
val parent = declaration.parent
|
||||||
val p = declaration.correspondingPropertySymbol?.let { composeSignatureForDeclaration(it.owner, true) }
|
val p = declaration.correspondingPropertySymbol?.let { composeSignatureForDeclaration(it.owner, true) }
|
||||||
?: composeContainerIdSignature(parent, compatibleMode)
|
?: composeContainerIdSignature(parent, compatibleMode)
|
||||||
IdSignature.FileLocalSignature(
|
declaration.createFileLocalSignature(
|
||||||
p,
|
p,
|
||||||
if (declaration.isOverridableFunction()) {
|
if (declaration.isOverridableFunction()) {
|
||||||
mangler.run { declaration.signatureMangle() }
|
mangler.run { declaration.signatureMangle() }
|
||||||
@@ -262,7 +261,7 @@ open class IdSignatureSerializer(
|
|||||||
}
|
}
|
||||||
is IrProperty -> {
|
is IrProperty -> {
|
||||||
val parent = declaration.parent
|
val parent = declaration.parent
|
||||||
IdSignature.FileLocalSignature(
|
declaration.createFileLocalSignature(
|
||||||
composeContainerIdSignature(parent, compatibleMode),
|
composeContainerIdSignature(parent, compatibleMode),
|
||||||
|
|
||||||
if (declaration.isOverridableProperty()) {
|
if (declaration.isOverridableProperty()) {
|
||||||
@@ -274,9 +273,21 @@ open class IdSignatureSerializer(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
else -> {
|
else -> {
|
||||||
IdSignature.FileLocalSignature(composeContainerIdSignature(declaration.parent, compatibleMode), ++localIndex, declaration.render())
|
declaration.createFileLocalSignature(
|
||||||
|
composeContainerIdSignature(declaration.parent, compatibleMode),
|
||||||
|
++localIndex,
|
||||||
|
declaration.render()
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected open fun IrDeclaration.createFileLocalSignature(parentSignature: IdSignature, localIndex: Long): IdSignature {
|
||||||
|
return IdSignature.FileLocalSignature(parentSignature, localIndex)
|
||||||
|
}
|
||||||
|
|
||||||
|
protected open fun IrDeclaration.createScopeLocalSignature(scopeIndex: Int, description: String): IdSignature {
|
||||||
|
return IdSignature.ScopeLocalDeclaration(scopeIndex, description)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user