FIR: unify common special names scattered around the code base
This commit is contained in:
committed by
teamcityserver
parent
263b876e6e
commit
684ef871ee
+3
-2
@@ -21,6 +21,7 @@ import org.jetbrains.kotlin.ir.util.deepCopyWithSymbols
|
||||
import org.jetbrains.kotlin.ir.util.defaultType
|
||||
import org.jetbrains.kotlin.name.Name
|
||||
import org.jetbrains.kotlin.util.OperatorNameConventions
|
||||
import org.jetbrains.kotlin.name.SpecialNames
|
||||
import kotlin.reflect.KParameter
|
||||
import kotlin.reflect.KType
|
||||
import kotlin.reflect.KTypeParameter
|
||||
@@ -148,9 +149,9 @@ internal class KFunctionState(
|
||||
.toIntOrNull()
|
||||
}
|
||||
|
||||
private fun isLambda(): Boolean = irFunction.name.let { it == Name.special("<anonymous>") || it == Name.special("<no name provided>") }
|
||||
private fun isLambda(): Boolean = irFunction.name.let { it == SpecialNames.ANONYMOUS || it == Name.special("<no name provided>") }
|
||||
|
||||
override fun toString(): String {
|
||||
return if (isLambda()) renderLambda(irFunction) else renderFunction(irFunction)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user