[KLIB] Drop unused logger
This commit is contained in:
-7
@@ -169,7 +169,6 @@ abstract class IrFileDeserializer(
|
|||||||
private fun deserializeSimpleType(proto: ProtoSimpleType): IrSimpleType {
|
private fun deserializeSimpleType(proto: ProtoSimpleType): IrSimpleType {
|
||||||
val symbol = deserializeIrSymbolAndRemap(proto.classifier) as? IrClassifierSymbol
|
val symbol = deserializeIrSymbolAndRemap(proto.classifier) as? IrClassifierSymbol
|
||||||
?: error("could not convert sym to ClassifierSymbol")
|
?: error("could not convert sym to ClassifierSymbol")
|
||||||
logger.log { "deserializeSimpleType: symbol=$symbol" }
|
|
||||||
|
|
||||||
val arguments = proto.argumentList.map { deserializeIrTypeArgument(it) }
|
val arguments = proto.argumentList.map { deserializeIrTypeArgument(it) }
|
||||||
val annotations = deserializeAnnotations(proto.annotationList)
|
val annotations = deserializeAnnotations(proto.annotationList)
|
||||||
@@ -182,7 +181,6 @@ abstract class IrFileDeserializer(
|
|||||||
annotations,
|
annotations,
|
||||||
if (proto.hasAbbreviation()) deserializeTypeAbbreviation(proto.abbreviation) else null
|
if (proto.hasAbbreviation()) deserializeTypeAbbreviation(proto.abbreviation) else null
|
||||||
)
|
)
|
||||||
logger.log { "ir_type = $result; render = ${result.render()}" }
|
|
||||||
return result
|
return result
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -322,8 +320,6 @@ abstract class IrFileDeserializer(
|
|||||||
-> TODO("Statement deserialization not implemented: ${proto.statementCase}")
|
-> TODO("Statement deserialization not implemented: ${proto.statementCase}")
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.log { "### Deserialized statement: ${ir2string(element)}" }
|
|
||||||
|
|
||||||
return element
|
return element
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -938,7 +934,6 @@ abstract class IrFileDeserializer(
|
|||||||
val operation = proto.operation
|
val operation = proto.operation
|
||||||
val expression = deserializeOperation(operation, start, end, type)
|
val expression = deserializeOperation(operation, start, end, type)
|
||||||
|
|
||||||
logger.log { "### Deserialized expression: ${ir2string(expression)} ir_type=$type" }
|
|
||||||
return expression
|
return expression
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1429,8 +1424,6 @@ abstract class IrFileDeserializer(
|
|||||||
DECLARATOR_NOT_SET -> error("Declaration deserialization not implemented: ${proto.declaratorCase}")
|
DECLARATOR_NOT_SET -> error("Declaration deserialization not implemented: ${proto.declaratorCase}")
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.log { "### Deserialized declaration: ${declaration.descriptor} -> ${ir2string(declaration)}" }
|
|
||||||
|
|
||||||
return declaration
|
return declaration
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+6
-12
@@ -348,7 +348,6 @@ open class IrFileSerializer(
|
|||||||
.build()
|
.build()
|
||||||
|
|
||||||
private fun serializeIrTypeData(type: IrType): ProtoType {
|
private fun serializeIrTypeData(type: IrType): ProtoType {
|
||||||
logger.log { "### serializing IrType: $type" }
|
|
||||||
val proto = ProtoType.newBuilder()
|
val proto = ProtoType.newBuilder()
|
||||||
when (type) {
|
when (type) {
|
||||||
is IrSimpleType ->
|
is IrSimpleType ->
|
||||||
@@ -917,8 +916,6 @@ open class IrFileSerializer(
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun serializeExpression(expression: IrExpression): ProtoExpression {
|
private fun serializeExpression(expression: IrExpression): ProtoExpression {
|
||||||
logger.log { "### serializing Expression: ${ir2string(expression)}" }
|
|
||||||
|
|
||||||
val coordinates = serializeCoordinates(expression.startOffset, expression.endOffset)
|
val coordinates = serializeCoordinates(expression.startOffset, expression.endOffset)
|
||||||
val proto = ProtoExpression.newBuilder()
|
val proto = ProtoExpression.newBuilder()
|
||||||
.setType(serializeIrType(expression.type))
|
.setType(serializeIrType(expression.type))
|
||||||
@@ -973,7 +970,6 @@ open class IrFileSerializer(
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun serializeStatement(statement: IrElement): ProtoStatement {
|
private fun serializeStatement(statement: IrElement): ProtoStatement {
|
||||||
logger.log { "### serializing Statement: ${ir2string(statement)}" }
|
|
||||||
|
|
||||||
val coordinates = serializeCoordinates(statement.startOffset, statement.endOffset)
|
val coordinates = serializeCoordinates(statement.startOffset, statement.endOffset)
|
||||||
val proto = ProtoStatement.newBuilder()
|
val proto = ProtoStatement.newBuilder()
|
||||||
@@ -981,22 +977,22 @@ open class IrFileSerializer(
|
|||||||
|
|
||||||
when (statement) {
|
when (statement) {
|
||||||
is IrDeclaration -> {
|
is IrDeclaration -> {
|
||||||
logger.log { " ###Declaration " }; proto.declaration = serializeDeclaration(statement)
|
proto.declaration = serializeDeclaration(statement)
|
||||||
}
|
}
|
||||||
is IrExpression -> {
|
is IrExpression -> {
|
||||||
logger.log { " ###Expression " }; proto.expression = serializeExpression(statement)
|
proto.expression = serializeExpression(statement)
|
||||||
}
|
}
|
||||||
is IrBlockBody -> {
|
is IrBlockBody -> {
|
||||||
logger.log { " ###BlockBody " }; proto.blockBody = serializeBlockBody(statement)
|
proto.blockBody = serializeBlockBody(statement)
|
||||||
}
|
}
|
||||||
is IrBranch -> {
|
is IrBranch -> {
|
||||||
logger.log { " ###Branch " }; proto.branch = serializeBranch(statement)
|
proto.branch = serializeBranch(statement)
|
||||||
}
|
}
|
||||||
is IrCatch -> {
|
is IrCatch -> {
|
||||||
logger.log { " ###Catch " }; proto.catch = serializeCatch(statement)
|
proto.catch = serializeCatch(statement)
|
||||||
}
|
}
|
||||||
is IrSyntheticBody -> {
|
is IrSyntheticBody -> {
|
||||||
logger.log { " ###SyntheticBody " }; proto.syntheticBody = serializeSyntheticBody(statement)
|
proto.syntheticBody = serializeSyntheticBody(statement)
|
||||||
}
|
}
|
||||||
else -> {
|
else -> {
|
||||||
TODO("Statement not implemented yet: ${ir2string(statement)}")
|
TODO("Statement not implemented yet: ${ir2string(statement)}")
|
||||||
@@ -1191,8 +1187,6 @@ open class IrFileSerializer(
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun serializeDeclaration(declaration: IrDeclaration): ProtoDeclaration {
|
private fun serializeDeclaration(declaration: IrDeclaration): ProtoDeclaration {
|
||||||
logger.log { "### serializing Declaration: ${ir2string(declaration)}" }
|
|
||||||
|
|
||||||
val proto = ProtoDeclaration.newBuilder()
|
val proto = ProtoDeclaration.newBuilder()
|
||||||
|
|
||||||
when (declaration) {
|
when (declaration) {
|
||||||
|
|||||||
Reference in New Issue
Block a user