[Wasm] Generate comments for inlined calls
This commit is contained in:
+7
@@ -656,6 +656,12 @@ class BodyGenerator(
|
||||
}
|
||||
|
||||
if (expression is IrReturnableBlock) {
|
||||
val inlineFunction = expression.symbol.owner.inlineFunction
|
||||
val correspondingProperty = (inlineFunction as? IrSimpleFunction)?.correspondingPropertySymbol
|
||||
val owner = correspondingProperty?.owner ?: inlineFunction
|
||||
val name = owner?.fqNameWhenAvailable?.asString() ?: owner?.name?.asString() ?: "<UNKNOWN>"
|
||||
|
||||
body.commentGroupStart { "Inlined call of `$name`" }
|
||||
functionContext.defineNonLocalReturnLevel(
|
||||
expression.symbol,
|
||||
body.buildBlock(context.transformBlockResultType(expression.type))
|
||||
@@ -679,6 +685,7 @@ class BodyGenerator(
|
||||
|
||||
if (expression is IrReturnableBlock) {
|
||||
body.buildEnd()
|
||||
body.commentGroupEnd()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user