提交 c54354f3 编写于 作者: I Ilya Kirillov

FIR: fix memory leak from ConeIntegerLiteralTypeImpl via static NUMBER_TYPE

ConeClassLikeType has a cachedExpanded type which has a strong ref to FirSession
上级 ede5fef3
......@@ -62,7 +62,7 @@ class ConeIntegerLiteralTypeImpl : ConeIntegerLiteralType {
override val supertypes: List<ConeClassLikeType> by lazy {
listOf(
NUMBER_TYPE,
createType(StandardClassIds.Number),
ConeClassLikeTypeImpl(COMPARABLE_TAG, arrayOf(ConeKotlinTypeProjectionIn(this)), false)
)
}
......@@ -83,8 +83,6 @@ class ConeIntegerLiteralTypeImpl : ConeIntegerLiteralType {
return ConeClassLikeTypeImpl(ConeClassLikeLookupTagImpl(classId), emptyArray(), false)
}
private val NUMBER_TYPE = createType(StandardClassIds.Number)
private val INT_RANGE = Int.MIN_VALUE.toLong()..Int.MAX_VALUE.toLong()
private val BYTE_RANGE = Byte.MIN_VALUE.toLong()..Byte.MAX_VALUE.toLong()
private val SHORT_RANGE = Short.MIN_VALUE.toLong()..Short.MAX_VALUE.toLong()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册