[FIR] optimize ConeTypeProjection[] RAM usage for empty arrays
On the snapshot from ^KTIJ-26260 empty ConeTypeProjection arrays take about 10mb
This commit is contained in:
committed by
Space Team
parent
bdfc68468f
commit
e763e71515
@@ -14,10 +14,12 @@ import org.jetbrains.kotlin.util.WeakPair
|
||||
|
||||
class ConeClassLikeTypeImpl(
|
||||
override val lookupTag: ConeClassLikeLookupTag,
|
||||
override val typeArguments: Array<out ConeTypeProjection>,
|
||||
typeArguments: Array<out ConeTypeProjection>,
|
||||
isNullable: Boolean,
|
||||
override val attributes: ConeAttributes = ConeAttributes.Empty
|
||||
) : ConeClassLikeType() {
|
||||
override val typeArguments = if (typeArguments.isEmpty()) EMPTY_ARRAY else typeArguments
|
||||
|
||||
override val nullability: ConeNullability = ConeNullability.create(isNullable)
|
||||
|
||||
// Cached expanded type and the relevant session
|
||||
|
||||
Reference in New Issue
Block a user