Remove obsolete and unused descriptors and utils

This commit is contained in:
Alexander Udalov
2019-03-19 18:10:34 +01:00
parent 72ca05f86a
commit dada35d785
7 changed files with 18 additions and 324 deletions
@@ -127,7 +127,6 @@ class IrBuiltIns(
val collectionClass = builtIns.collection.toIrSymbol()
val arrayType = builtIns.array.toIrType(symbolTable = symbolTable)
val arrayClass = builtIns.array.toIrSymbol()
val throwableType = builtIns.throwable.defaultType.toIrType()
@@ -107,11 +107,6 @@ private fun makeKotlinType(
return classifier.descriptor.defaultType.replace(newArguments = kotlinTypeArguments).makeNullableAsSpecified(hasQuestionMark)
}
fun ClassifierDescriptor.toIrType(hasQuestionMark: Boolean = false, symbolTable: SymbolTable? = null): IrType {
val symbol = getSymbol(symbolTable)
return IrSimpleTypeImpl(defaultType, symbol, hasQuestionMark, listOf(), listOf())
}
val IrTypeParameter.defaultType: IrType
get() = IrSimpleTypeImpl(
symbol,
@@ -155,4 +150,4 @@ private fun ClassifierDescriptor.getSymbol(symbolTable: SymbolTable?): IrClassif
is ClassDescriptor -> symbolTable?.referenceClass(this) ?: IrClassSymbolImpl(this)
is TypeParameterDescriptor -> symbolTable?.referenceTypeParameter(this) ?: IrTypeParameterSymbolImpl(this)
else -> TODO()
}
}