[IR] Don't use the GET_PROPERTY origin on IrGetField expressions.

This origin was set somewhat arbitrarily.
It actually only makes sense for `IrCall`s to property getters.
There were no places in lowerings that checked `IrGetField` expressions
for this origin value.

^KT-62500 Fixed
This commit is contained in:
Sergej Jaskiewicz
2024-01-10 18:45:11 +01:00
committed by Space Team
parent f9ea353b60
commit ad9f7bf90e
49 changed files with 75 additions and 75 deletions
@@ -214,8 +214,7 @@ internal class CallGenerator(statementGenerator: StatementGenerator) : Statement
fieldSymbol,
irType,
dispatchReceiverValue?.load() ?: extensionReceiverValue?.load(),
IrStatementOrigin.GET_PROPERTY,
superQualifierSymbol
superQualifierSymbol = superQualifierSymbol
).also { context.callToSubstitutedDescriptorMap[it] = descriptor }
}
} else {
@@ -75,7 +75,11 @@ interface IrStatementOrigin {
val ARGUMENTS_REORDERING_FOR_CALL by IrStatementOriginImpl
val DESTRUCTURING_DECLARATION by IrStatementOriginImpl
/**
* Used on an [IrCall] expression to indicate that it's a call to a property getter.
*/
val GET_PROPERTY by IrStatementOriginImpl
val GET_LOCAL_PROPERTY by IrStatementOriginImpl
val IF by IrStatementOriginImpl