Add new filed attributeOwnerIdBeforeInline to IrAttributeContainer

This field is null by default, and it is set to current
`attributeOwnerId` when declaration was inlined and must be
generated with new name. In its turn `attributeOwnerId` must be set to
`this` to show that this is actually a new declaration, not a copy.
This commit is contained in:
Ivan Kylchik
2022-08-01 16:39:18 +02:00
committed by Space Team
parent 163ed20de5
commit 60702f0f02
13 changed files with 29 additions and 0 deletions
@@ -91,6 +91,7 @@ abstract class AbstractFir2IrLazyFunction<F : FirCallableDeclaration>(
override var correspondingPropertySymbol: IrPropertySymbol? = null
override var attributeOwnerId: IrAttributeContainer = this
override var attributeOwnerIdBeforeInline: IrAttributeContainer? = null
override var metadata: MetadataSource?
get() = null
@@ -72,6 +72,12 @@ class Fir2IrLazyClass(
get() = this
set(_) = mutationNotSupported()
override var attributeOwnerIdBeforeInline: IrAttributeContainer?
get() = null
set(_) {
error("Mutating Fir2Ir lazy elements is not possible")
}
override var kind: ClassKind
get() = fir.classKind
set(_) = mutationNotSupported()
@@ -235,4 +235,5 @@ class Fir2IrLazyProperty(
get() = fir.containerSource
override var attributeOwnerId: IrAttributeContainer = this
override var attributeOwnerIdBeforeInline: IrAttributeContainer? = null
}