IR: make subtypes of IrDeclaration classes

This commit is contained in:
Alexander Udalov
2020-07-22 14:09:30 +02:00
parent 3cecf81176
commit 771e7574f4
54 changed files with 152 additions and 157 deletions
@@ -32,7 +32,7 @@ class IrAnonymousInitializerImpl(
override var origin: IrDeclarationOrigin,
override val symbol: IrAnonymousInitializerSymbol,
override val isStatic: Boolean = false
) : IrAnonymousInitializer {
) : IrAnonymousInitializer() {
init {
symbol.bind(this)
}
@@ -41,7 +41,7 @@ class IrClassImpl(
override val isExpect: Boolean = false,
override val isFun: Boolean = false,
override val source: SourceElement = SourceElement.NO_SOURCE
) : IrClass {
) : IrClass() {
init {
symbol.bind(this)
}
@@ -38,7 +38,7 @@ class IrConstructorImpl(
override val isExternal: Boolean,
override val isPrimary: Boolean,
override val isExpect: Boolean,
) : IrConstructor {
) : IrConstructor() {
init {
symbol.bind(this)
}
@@ -30,7 +30,7 @@ class IrEnumEntryImpl(
override var origin: IrDeclarationOrigin,
override val symbol: IrEnumEntrySymbol,
override val name: Name
) : IrEnumEntry {
) : IrEnumEntry() {
init {
symbol.bind(this)
}
@@ -29,7 +29,7 @@ class IrErrorDeclarationImpl(
override val startOffset: Int,
override val endOffset: Int,
override val descriptor: DeclarationDescriptor
) : IrErrorDeclaration {
) : IrErrorDeclaration() {
override var origin: IrDeclarationOrigin = IrDeclarationOrigin.DEFINED
override val factory: IrFactory
@@ -38,7 +38,7 @@ class IrFieldImpl(
override val isFinal: Boolean,
override val isExternal: Boolean,
override val isStatic: Boolean,
) : IrField {
) : IrField() {
init {
symbol.bind(this)
}
@@ -32,7 +32,7 @@ abstract class IrFunctionCommonImpl(
override val isOperator: Boolean,
override val isInfix: Boolean,
override val isExpect: Boolean,
) : IrSimpleFunction {
) : IrSimpleFunction() {
override val factory: IrFactory
get() = IrFactoryImpl
@@ -32,7 +32,7 @@ class IrLocalDelegatedPropertyImpl(
override val name: Name,
override val type: IrType,
override val isVar: Boolean
) : IrLocalDelegatedProperty {
) : IrLocalDelegatedProperty() {
init {
symbol.bind(this)
}
@@ -38,7 +38,7 @@ abstract class IrPropertyCommonImpl(
override val isDelegated: Boolean,
override val isExternal: Boolean,
override val isExpect: Boolean,
) : IrProperty {
) : IrProperty() {
override val factory: IrFactory
get() = IrFactoryImpl
@@ -23,7 +23,7 @@ class IrTypeAliasImpl(
override val expandedType: IrType,
override val isActual: Boolean,
override var origin: IrDeclarationOrigin
) : IrTypeAlias {
) : IrTypeAlias() {
init {
symbol.bind(this)
}
@@ -38,7 +38,7 @@ class IrTypeParameterImpl(
override val index: Int,
override val isReified: Boolean,
override val variance: Variance
) : IrTypeParameter {
) : IrTypeParameter() {
init {
symbol.bind(this)
}
@@ -39,7 +39,7 @@ class IrValueParameterImpl(
override val varargElementType: IrType?,
override val isCrossinline: Boolean,
override val isNoinline: Boolean
) : IrValueParameter {
) : IrValueParameter() {
@ObsoleteDescriptorBasedAPI
override val descriptor: ParameterDescriptor
get() = symbol.descriptor