[K/N] Add lowered suspend function mangling to avoid clashes
This commit is contained in:
committed by
Space Team
parent
2d4c94a115
commit
95eaf3d234
+1
@@ -21,6 +21,7 @@ enum class MangleConstant(val prefix: Char, val separator: Char, val suffix: Cha
|
||||
const val ERROR_MARK = "<ERROR CLASS>"
|
||||
const val ERROR_DECLARATION = "<ERROR DECLARATION>"
|
||||
const val STATIC_MEMBER_MARK = "#static"
|
||||
const val SUSPEND_FUNCTION_MARK = "#suspend"
|
||||
const val TYPE_PARAMETER_MARKER_NAME = "<TP>"
|
||||
const val TYPE_PARAMETER_MARKER_NAME_SETTER = "<STP>"
|
||||
const val BACKING_FIELD_NAME = "<BF>"
|
||||
|
||||
+5
@@ -28,6 +28,7 @@ abstract class IrMangleComputer(protected val builder: StringBuilder, private va
|
||||
private var isRealExpect = false
|
||||
|
||||
open fun IrFunction.platformSpecificFunctionName(): String? = null
|
||||
open fun IrFunction.platformSpecificFunctionMarks(): List<String> = emptyList()
|
||||
|
||||
open fun IrFunction.specialValueParamPrefix(param: IrValueParameter): String = ""
|
||||
|
||||
@@ -112,6 +113,10 @@ abstract class IrMangleComputer(protected val builder: StringBuilder, private va
|
||||
builder.appendSignature(MangleConstant.STATIC_MEMBER_MARK)
|
||||
}
|
||||
|
||||
platformSpecificFunctionMarks().forEach {
|
||||
builder.appendSignature(it)
|
||||
}
|
||||
|
||||
extensionReceiverParameter?.let {
|
||||
if (!it.isHidden) {
|
||||
builder.appendSignature(MangleConstant.EXTENSION_RECEIVER_PREFIX)
|
||||
|
||||
Reference in New Issue
Block a user