From 9d02fe564c2ae6600f764afb8b6957b7c5034c8a Mon Sep 17 00:00:00 2001 From: Denis Zharkov Date: Tue, 18 Jun 2019 12:50:14 +0300 Subject: [PATCH] FIR: Avoid calling ClassId::asString from ConeTypeContext --- .../src/org/jetbrains/kotlin/fir/types/ConeTypeContext.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/types/ConeTypeContext.kt b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/types/ConeTypeContext.kt index 724b375a5e1..5c15dea2e89 100644 --- a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/types/ConeTypeContext.kt +++ b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/types/ConeTypeContext.kt @@ -338,14 +338,13 @@ interface ConeTypeContext : TypeSystemContext, TypeSystemOptimizationContext { } override fun TypeConstructorMarker.isAnyConstructor(): Boolean { - return this is ConeClassLikeSymbol && classId.asString() == "kotlin/Any" + return this is ConeClassLikeSymbol && classId == StandardClassIds.Any } override fun TypeConstructorMarker.isNothingConstructor(): Boolean { - return this is ConeClassLikeSymbol && classId.asString() == "kotlin/Nothing" + return this is ConeClassLikeSymbol && classId == StandardClassIds.Nothing } - override fun KotlinTypeMarker.isNotNullNothing(): Boolean { require(this is ConeKotlinType) return typeConstructor().isNothingConstructor() && !this.nullability.isNullable