summaryrefslogtreecommitdiff
path: root/compiler/types/Type.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/types/Type.hs')
-rw-r--r--compiler/types/Type.hs11
1 files changed, 6 insertions, 5 deletions
diff --git a/compiler/types/Type.hs b/compiler/types/Type.hs
index 8450cd2f84..963fad4068 100644
--- a/compiler/types/Type.hs
+++ b/compiler/types/Type.hs
@@ -340,7 +340,7 @@ coreView (TyConApp tc tys) | Just (tenv, rhs, tys') <- expandSynTyCon_maybe tc t
-- partially-applied type constructor; indeed, usually will!
coreView (TyConApp tc []) -- At the Core level, Constraint = Type
- | isStarKindSynonymTyCon tc
+ | isConstraintKindCon tc
= Just liftedTypeKind
coreView _ = Nothing
@@ -2298,13 +2298,14 @@ nonDetCmpTypesX _ [] _ = LT
nonDetCmpTypesX _ _ [] = GT
-------------
--- | Compare two 'TyCon's. NB: This should /never/ see the "star synonyms",
--- as recognized by Kind.isStarKindSynonymTyCon. See Note
--- [Kind Constraint and kind *] in Kind.
+-- | Compare two 'TyCon's. NB: This should /never/ see 'Constraint' (as
+-- recognized by Kind.isConstraintKindCon) which is considered a synonym for
+-- 'Type' in Core.
+-- See Note [Kind Constraint and kind Type] in Kind.
-- See Note [nonDetCmpType nondeterminism]
nonDetCmpTc :: TyCon -> TyCon -> Ordering
nonDetCmpTc tc1 tc2
- = ASSERT( not (isStarKindSynonymTyCon tc1) && not (isStarKindSynonymTyCon tc2) )
+ = ASSERT( not (isConstraintKindCon tc1) && not (isConstraintKindCon tc2) )
u1 `nonDetCmpUnique` u2
where
u1 = tyConUnique tc1