[BE JVM] KT-51271 Set proper indices generating contextual inline call
[Tests] Test inline call with context receivers and default params
This commit is contained in:
committed by
teamcity
parent
dc210fa6ef
commit
4b366ddcf6
+1
-1
@@ -505,7 +505,7 @@ class ExpressionCodegen(
|
||||
callGenerator.genValueAndPut(callee.extensionReceiverParameter!!, receiver, type, this, data)
|
||||
}
|
||||
|
||||
callGenerator.beforeValueParametersStart()
|
||||
callGenerator.beforeValueParametersStart(callee.contextReceiverParametersCount)
|
||||
callee.valueParameters.subList(callee.contextReceiverParametersCount, callee.valueParameters.size)
|
||||
.forEachIndexed { i, valueParameter -> handleValueParameter(i + contextReceivers.size, valueParameter) }
|
||||
|
||||
|
||||
+1
-1
@@ -36,7 +36,7 @@ interface IrCallGenerator {
|
||||
|
||||
fun beforeCallStart() {}
|
||||
|
||||
fun beforeValueParametersStart() {}
|
||||
fun beforeValueParametersStart(contextReceiversCount: Int) {}
|
||||
|
||||
fun afterCallEnd() {}
|
||||
|
||||
|
||||
+2
-2
@@ -150,8 +150,8 @@ class IrInlineCodegen(
|
||||
}
|
||||
}
|
||||
|
||||
override fun beforeValueParametersStart() {
|
||||
invocationParamBuilder.markValueParametersStart()
|
||||
override fun beforeValueParametersStart(contextReceiversCount: Int) {
|
||||
invocationParamBuilder.markValueParametersStart(contextReceiversCount)
|
||||
}
|
||||
|
||||
override fun genInlineCall(
|
||||
|
||||
Reference in New Issue
Block a user