@@ -599,9 +599,6 @@ check' v@(Constructor c) ty = do
599check' (Let ds val) ty = do
599check' (Let ds val) ty = do
600 (ds', val') <- inferLetBinding [] ds val (`check` ty)
600 (ds', val') <- inferLetBinding [] ds val (`check` ty)
601 return $ TypedValue True (Let ds' val') ty
601 return $ TypedValue True (Let ds' val') ty
602−check' val ty | containsTypeSynonyms ty = do
603− ty' <- introduceSkolemScope <=< expandAllTypeSynonyms <=< replaceTypeWildcards $ ty
605check' val kt@(KindedType ty kind) = do
602check' val kt@(KindedType ty kind) = do
606 checkTypeKind ty kind
603 checkTypeKind ty kind
607 val' <- check' val ty
604 val' <- check' val ty
@@ -615,12 +612,6 @@ check' val ty = do
615 Nothing -> throwError . errorMessage $ SubsumptionCheckFailed
612 Nothing -> throwError . errorMessage $ SubsumptionCheckFailed
616 Just v' -> return $ TypedValue True v' ty
613 Just v' -> return $ TypedValue True v' ty
618−containsTypeSynonyms :: Type -> Bool
619−containsTypeSynonyms = everythingOnTypes (||) go where
620− go (SaturatedTypeSynonym _ _) = True
625-- Check the type of a collection of named record fields
616-- Check the type of a collection of named record fields