X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;ds=sidebyside;f=compiler%2Frename%2FRnTypes.lhs;h=88e3e2681a13b11c59a65c59df3cffc1b855e52f;hb=c5b178be60a5a44abd2f4ddf8c399857678326e2;hp=8405e8cb2eeda423b7b038b5d12d9265c19aee53;hpb=34c8d0312071f7d0f4d221a997d3408c653ef9e5;p=ghc-hetmet.git diff --git a/compiler/rename/RnTypes.lhs b/compiler/rename/RnTypes.lhs index 8405e8c..88e3e26 100644 --- a/compiler/rename/RnTypes.lhs +++ b/compiler/rename/RnTypes.lhs @@ -31,7 +31,7 @@ import RnEnv import TcRnMonad import RdrName import PrelNames -import TypeRep ( funTyConName ) +import TysPrim ( funTyConName ) import Name import SrcLoc import NameSet @@ -139,13 +139,6 @@ rnHsType doc (HsRecTy flds) = do { flds' <- rnConDeclFields doc flds ; return (HsRecTy flds') } -rnHsType _ (HsNumTy i) - | i == 1 = return (HsNumTy i) - | otherwise = addErr err_msg >> return (HsNumTy i) - where - err_msg = ptext (sLit "Only unit numeric type pattern is valid") - - rnHsType doc (HsFunTy ty1 ty2) = do ty1' <- rnLHsType doc ty1 -- Might find a for-all as the arg of a function type @@ -175,6 +168,11 @@ rnHsType doc (HsModalBoxType ecn ty) = do ty' <- rnLHsType doc ty return (HsModalBoxType ecn' ty') +rnHsType doc (HsKappaTy ty1 ty2) = do + ty1' <- rnLHsType doc ty1 + ty2' <- rnLHsType doc ty2 + return $ HsKappaTy ty1' ty2' + -- Unboxed tuples are allowed to have poly-typed arguments. These -- sometimes crop up as a result of CPR worker-wrappering dictionaries. rnHsType doc (HsTupleTy tup_con tys) = do