FIR: support type alias resolve

This commit is contained in:
Mikhail Glukhikh
2018-03-20 18:10:56 +03:00
parent d5463193fd
commit f82ad6ac20
13 changed files with 130 additions and 19 deletions
@@ -30,4 +30,10 @@ abstract class ConeKotlinType : ConeKotlinTypeProjection(ProjectionKind.INVARIAN
abstract class ConeClassType : ConeKotlinType() {
abstract val fqName: ClassId
}
abstract class ConeAbbreviatedType : ConeClassType() {
abstract val abbreviationFqName: ClassId
abstract val directExpansion: ConeKotlinType
}
@@ -8,7 +8,7 @@ package org.jetbrains.kotlin.fir.types.impl
import org.jetbrains.kotlin.fir.types.*
import org.jetbrains.kotlin.name.ClassId
class ConeClassTypeImpl(
open class ConeClassTypeImpl(
override val fqName: ClassId,
override val typeArguments: List<ConeKotlinTypeProjection>
) : ConeClassType()
@@ -24,4 +24,13 @@ class ConeKotlinErrorType(val reason: String) : ConeKotlinType() {
override fun toString(): String {
return "<ERROR TYPE: $reason>"
}
}
class ConeAbbreviatedTypeImpl(
override val abbreviationFqName: ClassId,
override val typeArguments: List<ConeKotlinTypeProjection>,
override val directExpansion: ConeKotlinType
) : ConeAbbreviatedType() {
override val fqName: ClassId
get() = abbreviationFqName
}