diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/ConversionUtils.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/ConversionUtils.kt index 7c5025e05df..afb474c4ba4 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/ConversionUtils.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/ConversionUtils.kt @@ -353,6 +353,33 @@ private fun FirClass<*>.getSuperTypesAsIrClasses( return irClass.superTypes.mapNotNull { it.classifierOrNull?.owner as? IrClass }.toSet() } +internal fun FirProperty.generateOverriddenPropertySymbols( + containingClass: FirClass<*>, + session: FirSession, + scopeSession: ScopeSession, + declarationStorage: Fir2IrDeclarationStorage, + fakeOverrideGenerator: FakeOverrideGenerator, +): List { + val superClasses = containingClass.getSuperTypesAsIrClasses(declarationStorage) ?: return emptyList() + + val scope = containingClass.unsubstitutedScope(session, scopeSession, withForcedTypeCalculator = true) + scope.processPropertiesByName(name) {} + val overriddenSet = mutableSetOf() + scope.processOverriddenPropertiesFromSuperClasses(symbol, containingClass) { + if (it.fir.visibility == Visibilities.Private) { + return@processOverriddenPropertiesFromSuperClasses ProcessorAction.NEXT + } + + for (overridden in fakeOverrideGenerator.getOverriddenSymbolsInSupertypes(it, superClasses)) { + overriddenSet += overridden + } + + ProcessorAction.NEXT + } + + return overriddenSet.toList() +} + internal fun FirProperty.generateOverriddenAccessorSymbols( containingClass: FirClass<*>, isGetter: Boolean, diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/ClassMemberGenerator.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/ClassMemberGenerator.kt index cbebfaf5d82..5ff82ef32fd 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/ClassMemberGenerator.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/ClassMemberGenerator.kt @@ -156,6 +156,11 @@ internal class ClassMemberGenerator( val delegate = property.delegate val propertyType = property.returnTypeRef.toIrType() irProperty.initializeBackingField(property, initializerExpression = initializer ?: delegate) + if (containingClass != null) { + irProperty.overriddenSymbols = property.generateOverriddenPropertySymbols( + containingClass, session, scopeSession, declarationStorage, fakeOverrideGenerator + ) + } irProperty.getter?.setPropertyAccessorContent( property, property.getter, irProperty, propertyType, property.getter is FirDefaultPropertyGetter, diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/DelegatedMemberGenerator.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/DelegatedMemberGenerator.kt index 45aa9a6207a..e08f12d3b1a 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/DelegatedMemberGenerator.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/backend/generators/DelegatedMemberGenerator.kt @@ -161,6 +161,14 @@ internal class DelegatedMemberGenerator( firDelegateProperty, subClass, origin = IrDeclarationOrigin.DELEGATED_MEMBER, containingClass = firSubClass.symbol.toLookupTag() ) + delegateProperty.overriddenSymbols = + firDelegateProperty.generateOverriddenPropertySymbols( + firSubClass, + session, + scopeSession, + declarationStorage, + fakeOverrideGenerator + ) annotationGenerator.generate(delegateProperty, firDelegateProperty) delegateProperty.getter!!.body = createDelegateBody(irField, delegateProperty.getter!!, superProperty.getter!!) diff --git a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/lazy/Fir2IrLazyProperty.kt b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/lazy/Fir2IrLazyProperty.kt index 29f78679267..00e987a39bf 100644 --- a/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/lazy/Fir2IrLazyProperty.kt +++ b/compiler/fir/fir2ir/src/org/jetbrains/kotlin/fir/lazy/Fir2IrLazyProperty.kt @@ -7,8 +7,6 @@ package org.jetbrains.kotlin.fir.lazy import org.jetbrains.kotlin.descriptors.Modality import org.jetbrains.kotlin.descriptors.PropertyDescriptor -import org.jetbrains.kotlin.fir.backend.Fir2IrComponents -import org.jetbrains.kotlin.fir.backend.toIrConst import org.jetbrains.kotlin.fir.declarations.* import org.jetbrains.kotlin.fir.declarations.impl.FirDefaultPropertyGetter import org.jetbrains.kotlin.fir.declarations.impl.FirDefaultPropertySetter @@ -24,10 +22,11 @@ import org.jetbrains.kotlin.ir.util.isInterface import org.jetbrains.kotlin.name.Name import org.jetbrains.kotlin.serialization.deserialization.descriptors.DeserializedContainerSource import org.jetbrains.kotlin.descriptors.DescriptorVisibility -import org.jetbrains.kotlin.fir.backend.ConversionTypeContext +import org.jetbrains.kotlin.fir.backend.* import org.jetbrains.kotlin.fir.backend.ConversionTypeOrigin import org.jetbrains.kotlin.fir.symbols.Fir2IrSimpleFunctionSymbol import org.jetbrains.kotlin.ir.symbols.IrPropertySymbol +import org.jetbrains.kotlin.ir.symbols.IrSimpleFunctionSymbol class Fir2IrLazyProperty( components: Fir2IrComponents, @@ -185,7 +184,13 @@ class Fir2IrLazyProperty( } override var overriddenSymbols: List by lazyVar(lock) { - emptyList() // TODO calculate overridden symbols for property + fir.generateOverriddenPropertySymbols( + containingClass, + session, + scopeSession, + declarationStorage, + fakeOverrideGenerator + ) } override var metadata: MetadataSource? diff --git a/compiler/testData/codegen/box/smartCasts/kt44814.fir.txt b/compiler/testData/codegen/box/smartCasts/kt44814.fir.txt index 86950d654bf..02cdcb455ff 100644 --- a/compiler/testData/codegen/box/smartCasts/kt44814.fir.txt +++ b/compiler/testData/codegen/box/smartCasts/kt44814.fir.txt @@ -66,6 +66,8 @@ FILE fqName: fileName:/kt44814.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:psi type:.PsiElement visibility:private [final]' type=.PsiElement origin=null receiver: GET_VAR ': .FirPsiSourceElement declared in .FirPsiSourceElement.' type=.FirPsiSourceElement origin=null PROPERTY name:lighterASTNode visibility:public modality:FINAL [val] + overridden: + public abstract lighterASTNode: .LighterASTNode [val] FIELD PROPERTY_BACKING_FIELD name:lighterASTNode type:.LighterASTNode visibility:private [final] EXPRESSION_BODY GET_VAR 'lighterASTNode: .LighterASTNode declared in .FirPsiSourceElement.' type=.LighterASTNode origin=INITIALIZE_PROPERTY_FROM_PARAMETER @@ -79,6 +81,8 @@ FILE fqName: fileName:/kt44814.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:lighterASTNode type:.LighterASTNode visibility:private [final]' type=.LighterASTNode origin=null receiver: GET_VAR ': .FirPsiSourceElement declared in .FirPsiSourceElement.' type=.FirPsiSourceElement origin=null PROPERTY name:treeStructure visibility:public modality:FINAL [val] + overridden: + public abstract treeStructure: .FlyweightCapableTreeStructure [val] FIELD PROPERTY_BACKING_FIELD name:treeStructure type:.FlyweightCapableTreeStructure visibility:private [final] EXPRESSION_BODY GET_VAR 'treeStructure: .FlyweightCapableTreeStructure declared in .FirPsiSourceElement.' type=.FlyweightCapableTreeStructure origin=INITIALIZE_PROPERTY_FROM_PARAMETER @@ -113,6 +117,8 @@ FILE fqName: fileName:/kt44814.kt DELEGATING_CONSTRUCTOR_CALL 'protected constructor () [primary] declared in .FirSourceElement' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:FirLightSourceElement modality:FINAL visibility:public superTypes:[.FirSourceElement]' PROPERTY name:lighterASTNode visibility:public modality:FINAL [val] + overridden: + public abstract lighterASTNode: .LighterASTNode [val] FIELD PROPERTY_BACKING_FIELD name:lighterASTNode type:.LighterASTNode visibility:private [final] EXPRESSION_BODY GET_VAR 'lighterASTNode: .LighterASTNode declared in .FirLightSourceElement.' type=.LighterASTNode origin=INITIALIZE_PROPERTY_FROM_PARAMETER @@ -126,6 +132,8 @@ FILE fqName: fileName:/kt44814.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:lighterASTNode type:.LighterASTNode visibility:private [final]' type=.LighterASTNode origin=null receiver: GET_VAR ': .FirLightSourceElement declared in .FirLightSourceElement.' type=.FirLightSourceElement origin=null PROPERTY name:treeStructure visibility:public modality:FINAL [val] + overridden: + public abstract treeStructure: .FlyweightCapableTreeStructure [val] FIELD PROPERTY_BACKING_FIELD name:treeStructure type:.FlyweightCapableTreeStructure visibility:private [final] EXPRESSION_BODY GET_VAR 'treeStructure: .FlyweightCapableTreeStructure declared in .FirLightSourceElement.' type=.FlyweightCapableTreeStructure origin=INITIALIZE_PROPERTY_FROM_PARAMETER diff --git a/compiler/testData/ir/irText/classes/delegatedGenericImplementation.fir.txt b/compiler/testData/ir/irText/classes/delegatedGenericImplementation.fir.txt index f76947455fd..b88faf4c614 100644 --- a/compiler/testData/ir/irText/classes/delegatedGenericImplementation.fir.txt +++ b/compiler/testData/ir/irText/classes/delegatedGenericImplementation.fir.txt @@ -61,6 +61,8 @@ FILE fqName: fileName:/delegatedGenericImplementation.kt a: GET_VAR 'a: E of .Test1 declared in .Test1.foo' type=E of .Test1 origin=null b: GET_VAR 'b: B of .Test1.foo declared in .Test1.foo' type=B of .Test1.foo origin=null PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] + overridden: + public abstract id: kotlin.collections.Map.IBase, C of .IBase.>? [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN ($this:.Test1.Test1>, $receiver:C of .Test1.) returnType:kotlin.collections.Map.Test1, C of .Test1.>? correspondingProperty: PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] overridden: @@ -76,6 +78,8 @@ FILE fqName: fileName:/delegatedGenericImplementation.kt receiver: GET_VAR ': .Test1.Test1> declared in .Test1.' type=.Test1.Test1> origin=null $receiver: GET_VAR ': C of .Test1. declared in .Test1.' type=C of .Test1. origin=null PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [var] + overridden: + public abstract x: D of .IBase.? [var] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN ($this:.Test1.Test1>, $receiver:kotlin.collections.List.Test1.>) returnType:D of .Test1.? correspondingProperty: PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [var] overridden: @@ -143,6 +147,8 @@ FILE fqName: fileName:/delegatedGenericImplementation.kt a: GET_VAR 'a: kotlin.String declared in .Test2.foo' type=kotlin.String origin=null b: GET_VAR 'b: B of .Test2.foo declared in .Test2.foo' type=B of .Test2.foo origin=null PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] + overridden: + public abstract id: kotlin.collections.Map.IBase, C of .IBase.>? [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN ($this:.Test2, $receiver:C of .Test2.) returnType:kotlin.collections.Map.Test2.>? correspondingProperty: PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] overridden: @@ -158,6 +164,8 @@ FILE fqName: fileName:/delegatedGenericImplementation.kt receiver: GET_VAR ': .Test2 declared in .Test2.' type=.Test2 origin=null $receiver: GET_VAR ': C of .Test2. declared in .Test2.' type=C of .Test2. origin=null PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [var] + overridden: + public abstract x: D of .IBase.? [var] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN ($this:.Test2, $receiver:kotlin.collections.List.Test2.>) returnType:D of .Test2.? correspondingProperty: PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [var] overridden: diff --git a/compiler/testData/ir/irText/classes/delegatedImplementation.fir.txt b/compiler/testData/ir/irText/classes/delegatedImplementation.fir.txt index 55f4ba84ea4..a10db62b8ed 100644 --- a/compiler/testData/ir/irText/classes/delegatedImplementation.fir.txt +++ b/compiler/testData/ir/irText/classes/delegatedImplementation.fir.txt @@ -117,6 +117,8 @@ FILE fqName: fileName:/delegatedImplementation.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name: modality:FINAL visibility:local superTypes:[.IOther]' PROPERTY name:x visibility:public modality:FINAL [val] + overridden: + public abstract x: kotlin.String [val] FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:private [final] EXPRESSION_BODY GET_VAR 'x0: kotlin.String declared in .otherImpl' type=kotlin.String origin=null @@ -130,6 +132,8 @@ FILE fqName: fileName:/delegatedImplementation.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:x type:kotlin.String visibility:private [final]' type=kotlin.String origin=null receiver: GET_VAR ': .otherImpl. declared in .otherImpl..' type=.otherImpl. origin=null PROPERTY name:y visibility:public modality:FINAL [var] + overridden: + public abstract y: kotlin.Int [var] FIELD PROPERTY_BACKING_FIELD name:y type:kotlin.Int visibility:private EXPRESSION_BODY GET_VAR 'y0: kotlin.Int declared in .otherImpl' type=kotlin.Int origin=null @@ -153,6 +157,8 @@ FILE fqName: fileName:/delegatedImplementation.kt receiver: GET_VAR ': .otherImpl. declared in .otherImpl..' type=.otherImpl. origin=null value: GET_VAR ': kotlin.Int declared in .otherImpl..' type=kotlin.Int origin=null PROPERTY name:z1 visibility:public modality:FINAL [val] + overridden: + public abstract z1: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.otherImpl., $receiver:kotlin.Byte) returnType:kotlin.Int correspondingProperty: PROPERTY name:z1 visibility:public modality:FINAL [val] overridden: @@ -163,6 +169,8 @@ FILE fqName: fileName:/delegatedImplementation.kt RETURN type=kotlin.Nothing from='public final fun (): kotlin.Int declared in .otherImpl.' CONST Int type=kotlin.Int value=1 PROPERTY name:z2 visibility:public modality:FINAL [var] + overridden: + public abstract z2: kotlin.Int [var] FUN name: visibility:public modality:FINAL <> ($this:.otherImpl., $receiver:kotlin.Byte) returnType:kotlin.Int correspondingProperty: PROPERTY name:z2 visibility:public modality:FINAL [var] overridden: @@ -288,6 +296,8 @@ FILE fqName: fileName:/delegatedImplementation.kt EXPRESSION_BODY GET_OBJECT 'CLASS OBJECT name:BaseImpl modality:FINAL visibility:public superTypes:[.IBase]' type=.BaseImpl PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [val] + overridden: + public abstract x: kotlin.String [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Test2) returnType:kotlin.String correspondingProperty: PROPERTY DELEGATED_MEMBER name:x visibility:public modality:OPEN [val] overridden: @@ -299,6 +309,8 @@ FILE fqName: fileName:/delegatedImplementation.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_1> type:.IOther visibility:local [final]' type=.IOther origin=null receiver: GET_VAR ': .Test2 declared in .Test2.' type=.Test2 origin=null PROPERTY DELEGATED_MEMBER name:y visibility:public modality:OPEN [var] + overridden: + public abstract y: kotlin.Int [var] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Test2) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:y visibility:public modality:OPEN [var] overridden: @@ -321,6 +333,8 @@ FILE fqName: fileName:/delegatedImplementation.kt receiver: GET_VAR ': .Test2 declared in .Test2.' type=.Test2 origin=null : GET_VAR ': kotlin.Int declared in .Test2.' type=kotlin.Int origin=null PROPERTY DELEGATED_MEMBER name:z1 visibility:public modality:OPEN [val] + overridden: + public abstract z1: kotlin.Int [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Test2, $receiver:kotlin.Byte) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:z1 visibility:public modality:OPEN [val] overridden: @@ -334,6 +348,8 @@ FILE fqName: fileName:/delegatedImplementation.kt receiver: GET_VAR ': .Test2 declared in .Test2.' type=.Test2 origin=null $receiver: GET_VAR ': kotlin.Byte declared in .Test2.' type=kotlin.Byte origin=null PROPERTY DELEGATED_MEMBER name:z2 visibility:public modality:OPEN [var] + overridden: + public abstract z2: kotlin.Int [var] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Test2, $receiver:kotlin.Byte) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:z2 visibility:public modality:OPEN [var] overridden: diff --git a/compiler/testData/ir/irText/classes/qualifiedSuperCalls.fir.txt b/compiler/testData/ir/irText/classes/qualifiedSuperCalls.fir.txt index b57f9e0f031..6b01a1a04c3 100644 --- a/compiler/testData/ir/irText/classes/qualifiedSuperCalls.fir.txt +++ b/compiler/testData/ir/irText/classes/qualifiedSuperCalls.fir.txt @@ -66,6 +66,9 @@ FILE fqName: fileName:/qualifiedSuperCalls.kt CALL 'public open fun foo (): kotlin.Unit declared in .IRight' superQualifier='CLASS INTERFACE name:IRight modality:ABSTRACT visibility:public superTypes:[kotlin.Any]' type=kotlin.Unit origin=null $this: GET_VAR ': .CBoth declared in .CBoth.foo' type=.CBoth origin=null PROPERTY name:bar visibility:public modality:FINAL [val] + overridden: + public open bar: kotlin.Int [val] + public open bar: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.CBoth) returnType:kotlin.Int correspondingProperty: PROPERTY name:bar visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/classes/superCalls.fir.txt b/compiler/testData/ir/irText/classes/superCalls.fir.txt index 6fa9681fe6d..1f34c30766c 100644 --- a/compiler/testData/ir/irText/classes/superCalls.fir.txt +++ b/compiler/testData/ir/irText/classes/superCalls.fir.txt @@ -50,6 +50,8 @@ FILE fqName: fileName:/superCalls.kt CALL 'public open fun foo (): kotlin.Unit declared in .Base' superQualifier='CLASS CLASS name:Base modality:OPEN visibility:public superTypes:[kotlin.Any]' type=kotlin.Unit origin=null $this: GET_VAR ': .Derived declared in .Derived.foo' type=.Derived origin=null PROPERTY name:bar visibility:public modality:FINAL [val] + overridden: + public open bar: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.Derived) returnType:kotlin.String correspondingProperty: PROPERTY name:bar visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/classes/superCallsComposed.fir.txt b/compiler/testData/ir/irText/classes/superCallsComposed.fir.txt index 9092b993b0e..5bb8ed266a2 100644 --- a/compiler/testData/ir/irText/classes/superCallsComposed.fir.txt +++ b/compiler/testData/ir/irText/classes/superCallsComposed.fir.txt @@ -68,6 +68,9 @@ FILE fqName: fileName:/superCallsComposed.kt CALL 'public open fun foo (): kotlin.Unit declared in .Base' superQualifier='CLASS CLASS name:Base modality:OPEN visibility:public superTypes:[kotlin.Any]' type=kotlin.Unit origin=null $this: GET_VAR ': .Derived declared in .Derived.foo' type=.Derived origin=null PROPERTY name:bar visibility:public modality:FINAL [val] + overridden: + public open bar: kotlin.String [val] + public abstract bar: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.Derived) returnType:kotlin.String correspondingProperty: PROPERTY name:bar visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/declarations/annotations/annotationsOnDelegatedMembers.fir.txt b/compiler/testData/ir/irText/declarations/annotations/annotationsOnDelegatedMembers.fir.txt index 754ee9e4373..b37824ee756 100644 --- a/compiler/testData/ir/irText/declarations/annotations/annotationsOnDelegatedMembers.fir.txt +++ b/compiler/testData/ir/irText/declarations/annotations/annotationsOnDelegatedMembers.fir.txt @@ -84,6 +84,8 @@ FILE fqName: fileName:/annotationsOnDelegatedMembers.kt PROPERTY DELEGATED_MEMBER name:testVal visibility:public modality:OPEN [val] annotations: Ann + overridden: + public abstract testVal: kotlin.String [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.DFoo) returnType:kotlin.String correspondingProperty: PROPERTY DELEGATED_MEMBER name:testVal visibility:public modality:OPEN [val] overridden: @@ -97,6 +99,8 @@ FILE fqName: fileName:/annotationsOnDelegatedMembers.kt PROPERTY DELEGATED_MEMBER name:testExtVal visibility:public modality:OPEN [val] annotations: Ann + overridden: + public abstract testExtVal: kotlin.String [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.DFoo, $receiver:kotlin.String) returnType:kotlin.String correspondingProperty: PROPERTY DELEGATED_MEMBER name:testExtVal visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/declarations/annotations/inheritingDeprecation.fir.txt b/compiler/testData/ir/irText/declarations/annotations/inheritingDeprecation.fir.txt index d343db72db3..1c785aaf3dc 100644 --- a/compiler/testData/ir/irText/declarations/annotations/inheritingDeprecation.fir.txt +++ b/compiler/testData/ir/irText/declarations/annotations/inheritingDeprecation.fir.txt @@ -43,6 +43,8 @@ FILE fqName: fileName:/inheritingDeprecation.kt PROPERTY DELEGATED_MEMBER name:prop visibility:public modality:OPEN [val] annotations: Deprecated(message = '', replaceWith = , level = ) + overridden: + public open prop: kotlin.String [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Delegated) returnType:kotlin.String correspondingProperty: PROPERTY DELEGATED_MEMBER name:prop visibility:public modality:OPEN [val] overridden: @@ -56,6 +58,8 @@ FILE fqName: fileName:/inheritingDeprecation.kt PROPERTY DELEGATED_MEMBER name:extProp visibility:public modality:OPEN [val] annotations: Deprecated(message = '', replaceWith = , level = ) + overridden: + public open extProp: kotlin.String [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Delegated, $receiver:kotlin.String) returnType:kotlin.String correspondingProperty: PROPERTY DELEGATED_MEMBER name:extProp visibility:public modality:OPEN [val] overridden: @@ -127,6 +131,8 @@ FILE fqName: fileName:/inheritingDeprecation.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:ExplicitOverride modality:FINAL visibility:public superTypes:[.IFoo]' PROPERTY name:prop visibility:public modality:FINAL [val] + overridden: + public open prop: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.ExplicitOverride) returnType:kotlin.String correspondingProperty: PROPERTY name:prop visibility:public modality:FINAL [val] overridden: @@ -136,6 +142,8 @@ FILE fqName: fileName:/inheritingDeprecation.kt RETURN type=kotlin.Nothing from='public final fun (): kotlin.String declared in .ExplicitOverride' CONST String type=kotlin.String value="" PROPERTY name:extProp visibility:public modality:FINAL [val] + overridden: + public open extProp: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.ExplicitOverride, $receiver:kotlin.String) returnType:kotlin.String correspondingProperty: PROPERTY name:extProp visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/declarations/fakeOverrides.fir.txt b/compiler/testData/ir/irText/declarations/fakeOverrides.fir.txt index d71257392aa..b9652e9925b 100644 --- a/compiler/testData/ir/irText/declarations/fakeOverrides.fir.txt +++ b/compiler/testData/ir/irText/declarations/fakeOverrides.fir.txt @@ -68,6 +68,8 @@ FILE fqName: fileName:/fakeOverrides.kt : kotlin.String INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:Test1 modality:FINAL visibility:public superTypes:[.CFoo; .IFooStr; .IBar]' PROPERTY name:bar visibility:public modality:FINAL [val] + overridden: + public abstract bar: kotlin.Int [val] FIELD PROPERTY_BACKING_FIELD name:bar type:kotlin.Int visibility:private [final] EXPRESSION_BODY CONST Int type=kotlin.Int value=42 diff --git a/compiler/testData/ir/irText/declarations/inlineCollectionOfInlineClass.fir.txt b/compiler/testData/ir/irText/declarations/inlineCollectionOfInlineClass.fir.txt index f956029e21f..41ab54d3d36 100644 --- a/compiler/testData/ir/irText/declarations/inlineCollectionOfInlineClass.fir.txt +++ b/compiler/testData/ir/irText/declarations/inlineCollectionOfInlineClass.fir.txt @@ -84,6 +84,8 @@ FILE fqName: fileName:/inlineCollectionOfInlineClass.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:ms type:kotlin.collections.MutableSet<.IT> visibility:private [final]' type=kotlin.collections.MutableSet<.IT> origin=null receiver: GET_VAR ': .InlineMutableSet declared in .InlineMutableSet.' type=.InlineMutableSet origin=null PROPERTY name:size visibility:public modality:FINAL [val] + overridden: + public abstract size: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.InlineMutableSet) returnType:kotlin.Int correspondingProperty: PROPERTY name:size visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/declarations/kt35550.fir.txt b/compiler/testData/ir/irText/declarations/kt35550.fir.txt index c14dc8698a9..53fac91195b 100644 --- a/compiler/testData/ir/irText/declarations/kt35550.fir.txt +++ b/compiler/testData/ir/irText/declarations/kt35550.fir.txt @@ -31,6 +31,8 @@ FILE fqName: fileName:/kt35550.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:A modality:FINAL visibility:public superTypes:[.I]' PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] + overridden: + public open id: T of .I. [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN ($this:.A, $receiver:T of .A.) returnType:T of .A. correspondingProperty: PROPERTY DELEGATED_MEMBER name:id visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/declarations/localClassWithOverrides.fir.txt b/compiler/testData/ir/irText/declarations/localClassWithOverrides.fir.txt index b4420dd5abd..df5b005f3ec 100644 --- a/compiler/testData/ir/irText/declarations/localClassWithOverrides.fir.txt +++ b/compiler/testData/ir/irText/declarations/localClassWithOverrides.fir.txt @@ -46,6 +46,8 @@ FILE fqName: fileName:/localClassWithOverrides.kt $this: VALUE_PARAMETER name: type:.outer.Local BLOCK_BODY PROPERTY name:aval visibility:public modality:FINAL [val] + overridden: + public abstract aval: kotlin.Int [val] FIELD PROPERTY_BACKING_FIELD name:aval type:kotlin.Int visibility:private [final] EXPRESSION_BODY CONST Int type=kotlin.Int value=1 @@ -59,6 +61,8 @@ FILE fqName: fileName:/localClassWithOverrides.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:aval type:kotlin.Int visibility:private [final]' type=kotlin.Int origin=null receiver: GET_VAR ': .outer.Local declared in .outer.Local.' type=.outer.Local origin=null PROPERTY name:avar visibility:public modality:FINAL [var] + overridden: + public abstract avar: kotlin.Int [var] FIELD PROPERTY_BACKING_FIELD name:avar type:kotlin.Int visibility:private EXPRESSION_BODY CONST Int type=kotlin.Int value=2 diff --git a/compiler/testData/ir/irText/declarations/parameters/delegatedMembers.fir.txt b/compiler/testData/ir/irText/declarations/parameters/delegatedMembers.fir.txt index cff1f2ce1b6..ae7cb163774 100644 --- a/compiler/testData/ir/irText/declarations/parameters/delegatedMembers.fir.txt +++ b/compiler/testData/ir/irText/declarations/parameters/delegatedMembers.fir.txt @@ -60,6 +60,8 @@ FILE fqName: fileName:/delegatedMembers.kt t: GET_VAR 't: TT of .Test declared in .Test.qux' type=TT of .Test origin=null x: GET_VAR 'x: X of .Test.qux declared in .Test.qux' type=X of .Test.qux origin=null PROPERTY DELEGATED_MEMBER name:bar visibility:public modality:OPEN [val] + overridden: + public abstract bar: kotlin.Int [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Test.Test>) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:bar visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/expressions/enumEntryAsReceiver.fir.txt b/compiler/testData/ir/irText/expressions/enumEntryAsReceiver.fir.txt index 6b8378f92cf..e42bf4f9ff6 100644 --- a/compiler/testData/ir/irText/expressions/enumEntryAsReceiver.fir.txt +++ b/compiler/testData/ir/irText/expressions/enumEntryAsReceiver.fir.txt @@ -27,6 +27,8 @@ FILE fqName: fileName:/enumEntryAsReceiver.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:value2 type:kotlin.String visibility:private [final]' type=kotlin.String origin=null receiver: GET_VAR ': .X.B declared in .X.B.' type=.X.B origin=null PROPERTY name:value visibility:public modality:FINAL [val] + overridden: + public abstract value: kotlin.Function0 [val] FIELD PROPERTY_BACKING_FIELD name:value type:kotlin.Function0 visibility:private [final] EXPRESSION_BODY FUN_EXPR type=kotlin.Function0 origin=LAMBDA diff --git a/compiler/testData/ir/irText/firProblems/AbstractMutableMap.fir.txt b/compiler/testData/ir/irText/firProblems/AbstractMutableMap.fir.txt index 1a2afee01f0..60ff1dfd8fc 100644 --- a/compiler/testData/ir/irText/firProblems/AbstractMutableMap.fir.txt +++ b/compiler/testData/ir/irText/firProblems/AbstractMutableMap.fir.txt @@ -20,6 +20,9 @@ FILE fqName: fileName:/AbstractMutableMap.kt RETURN type=kotlin.Nothing from='public final fun put (key: K of .MyMap, value: V of .MyMap): V of .MyMap? declared in .MyMap' CONST Null type=kotlin.Nothing? value=null PROPERTY name:entries visibility:public modality:FINAL [val] + overridden: + public abstract entries: @[FlexibleNullability] kotlin.collections.Set<@[FlexibleNullability] kotlin.collections.Map.Entry<@[FlexibleNullability] K of kotlin.collections.AbstractMutableMap?, @[FlexibleNullability] V of kotlin.collections.AbstractMutableMap?>?>? [fake_override,val] + public abstract entries: @[FlexibleNullability] kotlin.collections.Set<@[FlexibleNullability] kotlin.collections.Map.Entry<@[FlexibleNullability] K of java.util.AbstractMap?, @[FlexibleNullability] V of java.util.AbstractMap?>?>? [val] FUN name: visibility:public modality:FINAL <> ($this:.MyMap.MyMap, V of .MyMap>) returnType:kotlin.collections.MutableSet.MyMap, V of .MyMap>> correspondingProperty: PROPERTY name:entries visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/firProblems/ArrayMap.fir.txt b/compiler/testData/ir/irText/firProblems/ArrayMap.fir.txt index 9c06b0d45f0..9ef91dce74d 100644 --- a/compiler/testData/ir/irText/firProblems/ArrayMap.fir.txt +++ b/compiler/testData/ir/irText/firProblems/ArrayMap.fir.txt @@ -61,6 +61,8 @@ FILE fqName: fileName:/ArrayMap.kt : kotlin.Nothing INSTANCE_INITIALIZER_CALL classDescriptor='CLASS OBJECT name:EmptyArrayMap modality:FINAL visibility:internal superTypes:[.ArrayMap]' PROPERTY name:size visibility:public modality:FINAL [val] + overridden: + public abstract size: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.EmptyArrayMap) returnType:kotlin.Int correspondingProperty: PROPERTY name:size visibility:public modality:FINAL [val] overridden: @@ -182,6 +184,8 @@ FILE fqName: fileName:/ArrayMap.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:index type:kotlin.Int visibility:private [final]' type=kotlin.Int origin=null receiver: GET_VAR ': .OneElementArrayMap.OneElementArrayMap> declared in .OneElementArrayMap.' type=.OneElementArrayMap.OneElementArrayMap> origin=null PROPERTY name:size visibility:public modality:FINAL [val] + overridden: + public abstract size: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.OneElementArrayMap.OneElementArrayMap>) returnType:kotlin.Int correspondingProperty: PROPERTY name:size visibility:public modality:FINAL [val] overridden: @@ -395,6 +399,8 @@ FILE fqName: fileName:/ArrayMap.kt size: CALL 'private final fun (): kotlin.Int declared in .ArrayMapImpl.Companion' type=kotlin.Int origin=GET_PROPERTY $this: GET_OBJECT 'CLASS OBJECT name:Companion modality:FINAL visibility:public [companion] superTypes:[kotlin.Any]' type=.ArrayMapImpl.Companion PROPERTY name:size visibility:public modality:FINAL [var] + overridden: + public abstract size: kotlin.Int [val] FIELD PROPERTY_BACKING_FIELD name:size type:kotlin.Int visibility:private EXPRESSION_BODY CONST Int type=kotlin.Int value=0 @@ -681,6 +687,8 @@ FILE fqName: fileName:/ArrayMap.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:Entry modality:FINAL visibility:public [data] superTypes:[kotlin.collections.Map.Entry.ArrayMapImpl.Entry>]' PROPERTY name:key visibility:public modality:FINAL [val] + overridden: + public abstract key: K of kotlin.collections.Map.Entry [val] FIELD PROPERTY_BACKING_FIELD name:key type:kotlin.Int visibility:private [final] EXPRESSION_BODY GET_VAR 'key: kotlin.Int declared in .ArrayMapImpl.Entry.' type=kotlin.Int origin=INITIALIZE_PROPERTY_FROM_PARAMETER @@ -694,6 +702,8 @@ FILE fqName: fileName:/ArrayMap.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:key type:kotlin.Int visibility:private [final]' type=kotlin.Int origin=null receiver: GET_VAR ': .ArrayMapImpl.Entry.ArrayMapImpl.Entry> declared in .ArrayMapImpl.Entry.' type=.ArrayMapImpl.Entry.ArrayMapImpl.Entry> origin=null PROPERTY name:value visibility:public modality:FINAL [val] + overridden: + public abstract value: V of kotlin.collections.Map.Entry [val] FIELD PROPERTY_BACKING_FIELD name:value type:T of .ArrayMapImpl.Entry visibility:private [final] EXPRESSION_BODY GET_VAR 'value: T of .ArrayMapImpl.Entry declared in .ArrayMapImpl.Entry.' type=T of .ArrayMapImpl.Entry origin=INITIALIZE_PROPERTY_FROM_PARAMETER diff --git a/compiler/testData/ir/irText/firProblems/DelegationAndInheritanceFromJava.fir.txt b/compiler/testData/ir/irText/firProblems/DelegationAndInheritanceFromJava.fir.txt index 81ca2eb6b0a..88458a227a2 100644 --- a/compiler/testData/ir/irText/firProblems/DelegationAndInheritanceFromJava.fir.txt +++ b/compiler/testData/ir/irText/firProblems/DelegationAndInheritanceFromJava.fir.txt @@ -112,6 +112,9 @@ FILE fqName: fileName:/DelegationAndInheritanceFromJava.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:.Foo.B visibility:local [final]' type=.Foo.B origin=null receiver: GET_VAR ': .Impl declared in .Impl.isEmpty' type=.Impl origin=null PROPERTY DELEGATED_MEMBER name:size visibility:public modality:OPEN [val] + overridden: + public abstract size: kotlin.Int [fake_override,val] + public abstract size: kotlin.Int [fake_override,val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Impl) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:size visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/firProblems/Fir2IrClassifierStorage.fir.txt b/compiler/testData/ir/irText/firProblems/Fir2IrClassifierStorage.fir.txt index 26440e33b2d..74be316122a 100644 --- a/compiler/testData/ir/irText/firProblems/Fir2IrClassifierStorage.fir.txt +++ b/compiler/testData/ir/irText/firProblems/Fir2IrClassifierStorage.fir.txt @@ -61,6 +61,8 @@ FILE fqName: fileName:/Fir2IrClassifierStorage.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:Fir2IrComponentsStorage modality:FINAL visibility:public superTypes:[.Fir2IrComponents]' PROPERTY name:session visibility:public modality:FINAL [val] + overridden: + public abstract session: .FirSession [val] FIELD PROPERTY_BACKING_FIELD name:session type:.FirSession visibility:private [final] EXPRESSION_BODY GET_VAR 'session: .FirSession declared in .Fir2IrComponentsStorage.' type=.FirSession origin=INITIALIZE_PROPERTY_FROM_PARAMETER @@ -74,6 +76,8 @@ FILE fqName: fileName:/Fir2IrClassifierStorage.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:session type:.FirSession visibility:private [final]' type=.FirSession origin=null receiver: GET_VAR ': .Fir2IrComponentsStorage declared in .Fir2IrComponentsStorage.' type=.Fir2IrComponentsStorage origin=null PROPERTY name:classifierStorage visibility:public modality:FINAL [lateinit,var] + overridden: + public abstract classifierStorage: .Fir2IrClassifierStorage [val] FIELD PROPERTY_BACKING_FIELD name:classifierStorage type:.Fir2IrClassifierStorage visibility:public FUN DEFAULT_PROPERTY_ACCESSOR name: visibility:public modality:FINAL <> ($this:.Fir2IrComponentsStorage) returnType:.Fir2IrClassifierStorage correspondingProperty: PROPERTY name:classifierStorage visibility:public modality:FINAL [lateinit,var] @@ -113,6 +117,8 @@ FILE fqName: fileName:/Fir2IrClassifierStorage.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:Fir2IrClassifierStorage modality:FINAL visibility:public superTypes:[.Fir2IrComponents]' PROPERTY DELEGATED_MEMBER name:session visibility:public modality:OPEN [val] + overridden: + public abstract session: .FirSession [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Fir2IrClassifierStorage) returnType:.FirSession correspondingProperty: PROPERTY DELEGATED_MEMBER name:session visibility:public modality:OPEN [val] overridden: @@ -124,6 +130,8 @@ FILE fqName: fileName:/Fir2IrClassifierStorage.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:.Fir2IrComponents visibility:local [final]' type=.Fir2IrComponents origin=null receiver: GET_VAR ': .Fir2IrClassifierStorage declared in .Fir2IrClassifierStorage.' type=.Fir2IrClassifierStorage origin=null PROPERTY DELEGATED_MEMBER name:classifierStorage visibility:public modality:OPEN [val] + overridden: + public abstract classifierStorage: .Fir2IrClassifierStorage [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.Fir2IrClassifierStorage) returnType:.Fir2IrClassifierStorage correspondingProperty: PROPERTY DELEGATED_MEMBER name:classifierStorage visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.fir.txt b/compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.fir.txt index 84ce5fca631..6f7f3ac9463 100644 --- a/compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.fir.txt +++ b/compiler/testData/ir/irText/firProblems/ImplicitReceiverStack.fir.txt @@ -71,6 +71,8 @@ FILE fqName: fileName:/ImplicitReceiverStack.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:boundSymbol type:S of .ImplicitReceiverValue? visibility:private [final]' type=S of .ImplicitReceiverValue? origin=null receiver: GET_VAR ': .ImplicitReceiverValue.ImplicitReceiverValue> declared in .ImplicitReceiverValue.' type=.ImplicitReceiverValue.ImplicitReceiverValue> origin=null PROPERTY name:type visibility:public modality:FINAL [val] + overridden: + public abstract type: kotlin.String [val] FIELD PROPERTY_BACKING_FIELD name:type type:kotlin.String visibility:private [final] EXPRESSION_BODY GET_VAR 'type: kotlin.String declared in .ImplicitReceiverValue.' type=kotlin.String origin=INITIALIZE_PROPERTY_FROM_PARAMETER diff --git a/compiler/testData/ir/irText/firProblems/candidateSymbol.fir.txt b/compiler/testData/ir/irText/firProblems/candidateSymbol.fir.txt index 25bcafbb626..5629c824c2d 100644 --- a/compiler/testData/ir/irText/firProblems/candidateSymbol.fir.txt +++ b/compiler/testData/ir/irText/firProblems/candidateSymbol.fir.txt @@ -106,6 +106,8 @@ FILE fqName: fileName:/candidateSymbol.kt $this: VALUE_PARAMETER INSTANCE_RECEIVER name: type:.FirCallableMemberDeclaration.FirCallableMemberDeclaration> TYPE_PARAMETER name:F index:0 variance: superTypes:[.FirCallableMemberDeclaration.FirCallableMemberDeclaration>] PROPERTY name:symbol visibility:public modality:ABSTRACT [val] + overridden: + public abstract symbol: .AbstractFirBasedSymbol.FirSymbolOwner> [val] FUN DEFAULT_PROPERTY_ACCESSOR name: visibility:public modality:ABSTRACT <> ($this:.FirCallableMemberDeclaration.FirCallableMemberDeclaration>) returnType:.AbstractFirBasedSymbol.FirCallableMemberDeclaration> correspondingProperty: PROPERTY name:symbol visibility:public modality:ABSTRACT [val] overridden: diff --git a/compiler/testData/ir/irText/firProblems/kt43342.fir.txt b/compiler/testData/ir/irText/firProblems/kt43342.fir.txt index 268f0fc90a9..74cb7565786 100644 --- a/compiler/testData/ir/irText/firProblems/kt43342.fir.txt +++ b/compiler/testData/ir/irText/firProblems/kt43342.fir.txt @@ -67,6 +67,8 @@ FILE fqName: fileName:/kt43342.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> visibility:local [final]' type=kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> origin=null receiver: GET_VAR ': .ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> declared in .ControlFlowInfo.isEmpty' type=.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> origin=null PROPERTY DELEGATED_MEMBER name:entries visibility:public modality:OPEN [val] + overridden: + public abstract entries: kotlin.collections.Set> [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo>) returnType:kotlin.collections.Set.ControlFlowInfo, V of .ControlFlowInfo>> correspondingProperty: PROPERTY DELEGATED_MEMBER name:entries visibility:public modality:OPEN [val] overridden: @@ -78,6 +80,8 @@ FILE fqName: fileName:/kt43342.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> visibility:local [final]' type=kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> origin=null receiver: GET_VAR ': .ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> declared in .ControlFlowInfo.' type=.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> origin=null PROPERTY DELEGATED_MEMBER name:keys visibility:public modality:OPEN [val] + overridden: + public abstract keys: kotlin.collections.Set [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo>) returnType:kotlin.collections.Set.ControlFlowInfo> correspondingProperty: PROPERTY DELEGATED_MEMBER name:keys visibility:public modality:OPEN [val] overridden: @@ -89,6 +93,8 @@ FILE fqName: fileName:/kt43342.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> visibility:local [final]' type=kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> origin=null receiver: GET_VAR ': .ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> declared in .ControlFlowInfo.' type=.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> origin=null PROPERTY DELEGATED_MEMBER name:size visibility:public modality:OPEN [val] + overridden: + public abstract size: kotlin.Int [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo>) returnType:kotlin.Int correspondingProperty: PROPERTY DELEGATED_MEMBER name:size visibility:public modality:OPEN [val] overridden: @@ -100,6 +106,8 @@ FILE fqName: fileName:/kt43342.kt $this: GET_FIELD 'FIELD DELEGATE name:<$$delegate_0> type:kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> visibility:local [final]' type=kotlin.collections.Map.ControlFlowInfo, V of .ControlFlowInfo> origin=null receiver: GET_VAR ': .ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> declared in .ControlFlowInfo.' type=.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo> origin=null PROPERTY DELEGATED_MEMBER name:values visibility:public modality:OPEN [val] + overridden: + public abstract values: kotlin.collections.Collection [val] FUN DELEGATED_MEMBER name: visibility:public modality:OPEN <> ($this:.ControlFlowInfo.ControlFlowInfo, V of .ControlFlowInfo>) returnType:kotlin.collections.Collection.ControlFlowInfo> correspondingProperty: PROPERTY DELEGATED_MEMBER name:values visibility:public modality:OPEN [val] overridden: diff --git a/compiler/testData/ir/irText/firProblems/typeVariableAfterBuildMap.fir.txt b/compiler/testData/ir/irText/firProblems/typeVariableAfterBuildMap.fir.txt index 8a4680fdba9..21dfa3323cf 100644 --- a/compiler/testData/ir/irText/firProblems/typeVariableAfterBuildMap.fir.txt +++ b/compiler/testData/ir/irText/firProblems/typeVariableAfterBuildMap.fir.txt @@ -127,6 +127,8 @@ FILE fqName: fileName:/typeVariableAfterBuildMap.kt isPublicAPI: CONST Boolean type=kotlin.Boolean value=false INSTANCE_INITIALIZER_CALL classDescriptor='CLASS OBJECT name:PrivateToThis modality:FINAL visibility:public superTypes:[.Visibility]' PROPERTY name:internalDisplayName visibility:public modality:FINAL [val] + overridden: + public open internalDisplayName: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.Visibilities.PrivateToThis) returnType:kotlin.String correspondingProperty: PROPERTY name:internalDisplayName visibility:public modality:FINAL [val] overridden: @@ -450,6 +452,8 @@ FILE fqName: fileName:/typeVariableAfterBuildMap.kt RETURN type=kotlin.Nothing from='public final fun mustCheckInImports (): kotlin.Boolean declared in .Visibilities.InvisibleFake' CONST Boolean type=kotlin.Boolean value=true PROPERTY name:externalDisplayName visibility:public modality:FINAL [val] + overridden: + public open externalDisplayName: kotlin.String [val] FUN name: visibility:public modality:FINAL <> ($this:.Visibilities.InvisibleFake) returnType:kotlin.String correspondingProperty: PROPERTY name:externalDisplayName visibility:public modality:FINAL [val] overridden: diff --git a/compiler/testData/ir/irText/regressions/kt45236.fir.txt b/compiler/testData/ir/irText/regressions/kt45236.fir.txt index 8d340b09d7b..adf04b906a6 100644 --- a/compiler/testData/ir/irText/regressions/kt45236.fir.txt +++ b/compiler/testData/ir/irText/regressions/kt45236.fir.txt @@ -34,6 +34,8 @@ FILE fqName: fileName:/kt45236.kt GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:error type:kotlin.Throwable visibility:private [final]' type=kotlin.Throwable origin=null receiver: GET_VAR ': .NetRequestStatus.Error.NetRequestStatus.Error> declared in .NetRequestStatus.Error.' type=.NetRequestStatus.Error.NetRequestStatus.Error> origin=null PROPERTY name:value visibility:public modality:FINAL [val] + overridden: + public abstract value: T of .NetRequestStatus? [val] FIELD PROPERTY_BACKING_FIELD name:value type:T of .NetRequestStatus.Error? visibility:private [final] EXPRESSION_BODY GET_VAR 'value: T of .NetRequestStatus.Error? declared in .NetRequestStatus.Error.' type=T of .NetRequestStatus.Error? origin=INITIALIZE_PROPERTY_FROM_PARAMETER diff --git a/compiler/testData/ir/irText/stubs/genericClassInDifferentModule.fir.txt b/compiler/testData/ir/irText/stubs/genericClassInDifferentModule.fir.txt index 61e99d4c78a..448ea7ed81d 100644 --- a/compiler/testData/ir/irText/stubs/genericClassInDifferentModule.fir.txt +++ b/compiler/testData/ir/irText/stubs/genericClassInDifferentModule.fir.txt @@ -79,6 +79,8 @@ FILE fqName: fileName:/genericClassInDifferentModule_m2.kt CALL 'public final fun (): T of .Derived1 [fake_override] declared in .Derived1' type=T of .Derived1 origin=GET_PROPERTY $this: GET_VAR ': .Derived1.Derived1> declared in .Derived1.foo' type=.Derived1.Derived1> origin=null PROPERTY name:bar visibility:public modality:FINAL [var] + overridden: + public abstract bar: T of .Base [var] FIELD PROPERTY_BACKING_FIELD name:bar type:T of .Derived1 visibility:private EXPRESSION_BODY GET_VAR 'x: T of .Derived1 declared in .Derived1.' type=T of .Derived1 origin=null @@ -102,6 +104,8 @@ FILE fqName: fileName:/genericClassInDifferentModule_m2.kt receiver: GET_VAR ': .Derived1.Derived1> declared in .Derived1.' type=.Derived1.Derived1> origin=null value: GET_VAR ': T of .Derived1 declared in .Derived1.' type=T of .Derived1 origin=null PROPERTY name:exn visibility:public modality:FINAL [var] + overridden: + public abstract exn: T of .Base [var] FUN name: visibility:public modality:FINAL ($this:.Derived1.Derived1>, $receiver:Z of .Derived1.) returnType:T of .Derived1 correspondingProperty: PROPERTY name:exn visibility:public modality:FINAL [var] overridden: diff --git a/compiler/testData/ir/irText/types/nullChecks/implicitNotNullOnPlatformType.fir.txt b/compiler/testData/ir/irText/types/nullChecks/implicitNotNullOnPlatformType.fir.txt index ef5748bf9f4..9dc80cf7a7c 100644 --- a/compiler/testData/ir/irText/types/nullChecks/implicitNotNullOnPlatformType.fir.txt +++ b/compiler/testData/ir/irText/types/nullChecks/implicitNotNullOnPlatformType.fir.txt @@ -9,6 +9,8 @@ FILE fqName: fileName:/implicitNotNullOnPlatformType.kt DELEGATING_CONSTRUCTOR_CALL 'public constructor () [primary] declared in kotlin.Any' INSTANCE_INITIALIZER_CALL classDescriptor='CLASS CLASS name:MySet modality:FINAL visibility:public superTypes:[kotlin.collections.Set]' PROPERTY name:size visibility:public modality:FINAL [val] + overridden: + public abstract size: kotlin.Int [val] FUN name: visibility:public modality:FINAL <> ($this:.MySet) returnType:kotlin.Int correspondingProperty: PROPERTY name:size visibility:public modality:FINAL [val] overridden: