@@ -843,7 +843,8 @@ check' (TypedValue checkType val ty1) ty2 = do
843 Just moduleName <- checkCurrentModule <$> get
843 Just moduleName <- checkCurrentModule <$> get
844 kind <- liftCheck $ kindOf moduleName ty1
844 kind <- liftCheck $ kindOf moduleName ty1
845 guardWith ("Expected type of kind *, was " ++ prettyPrintKind kind) $ kind == Star
845 guardWith ("Expected type of kind *, was " ++ prettyPrintKind kind) $ kind == Star
846+ ty1' <- introduceSkolemScope <=< replaceAllTypeSynonyms $ ty1
846− val' <- subsumes (Just val) ty1 ty2
847+ val' <- subsumes (Just val) ty1' ty2
847 case val' of
848 case val' of
848 Nothing -> throwError "Unable to check type subsumption"
849 Nothing -> throwError "Unable to check type subsumption"
849 Just val'' -> do
850 Just val'' -> do