[FIR] Add forgotten replacing arguments in abbreviated type expansion

This commit is contained in:
Dmitriy Novozhilov
2019-07-29 10:01:34 +03:00
parent 317e3edba8
commit 6e2958880b
10 changed files with 249 additions and 21 deletions
@@ -18,7 +18,17 @@ sealed class ConeKotlinTypeProjection : TypeArgumentMarker {
}
enum class ProjectionKind {
STAR, IN, OUT, INVARIANT
STAR, IN, OUT, INVARIANT;
operator fun plus(other: ProjectionKind): ProjectionKind {
return when {
this == other -> this
this == STAR || other == STAR -> STAR
this == INVARIANT -> other
other == INVARIANT -> this
else -> STAR
}
}
}
object ConeStarProjection : ConeKotlinTypeProjection() {