diff options
| author | Ian Lynagh <igloo@earth.li> | 2012-06-14 12:46:48 +0100 |
|---|---|---|
| committer | Ian Lynagh <igloo@earth.li> | 2012-06-14 12:46:48 +0100 |
| commit | 0f3d8ab9f8c174f9aba5764a6b1edaf2c873b8c6 (patch) | |
| tree | 495a31e7dbb51aa89a9103d62ca12e4475cf6c15 /compiler/rename | |
| parent | 82a8ffd8179e0f99271a608e52f083d7a09d24ee (diff) | |
| parent | 1e9a2d34ae6996b6872ee4cc87bc8218360fcaf9 (diff) | |
| download | haskell-0f3d8ab9f8c174f9aba5764a6b1edaf2c873b8c6.tar.gz | |
Merge branch 'master' of darcs.haskell.org:/srv/darcs//ghc
Diffstat (limited to 'compiler/rename')
| -rw-r--r-- | compiler/rename/RnBinds.lhs | 7 | ||||
| -rw-r--r-- | compiler/rename/RnExpr.lhs | 3 | ||||
| -rw-r--r-- | compiler/rename/RnTypes.lhs | 11 |
3 files changed, 7 insertions, 14 deletions
diff --git a/compiler/rename/RnBinds.lhs b/compiler/rename/RnBinds.lhs index 536d83b344..d3d16033eb 100644 --- a/compiler/rename/RnBinds.lhs +++ b/compiler/rename/RnBinds.lhs @@ -35,7 +35,7 @@ import {-# SOURCE #-} RnExpr( rnLExpr, rnStmts ) import HsSyn import TcRnMonad import TcEvidence ( emptyTcEvBinds ) -import RnTypes ( bindSigTyVarsFV, rnIPName, rnHsSigType, rnLHsType, checkPrecMatch ) +import RnTypes ( bindSigTyVarsFV, rnHsSigType, rnLHsType, checkPrecMatch ) import RnPat import RnEnv import DynFlags @@ -220,10 +220,9 @@ rnIPBinds (IPBinds ip_binds _no_dict_binds) = do return (IPBinds ip_binds' emptyTcEvBinds, plusFVs fvs_s) rnIPBind :: IPBind RdrName -> RnM (IPBind Name, FreeVars) -rnIPBind (IPBind n expr) = do - n' <- rnIPName n +rnIPBind (IPBind ~(Left n) expr) = do (expr',fvExpr) <- rnLExpr expr - return (IPBind n' expr', fvExpr) + return (IPBind (Left n) expr', fvExpr) \end{code} diff --git a/compiler/rename/RnExpr.lhs b/compiler/rename/RnExpr.lhs index 3bb56ebfda..d27ef98e80 100644 --- a/compiler/rename/RnExpr.lhs +++ b/compiler/rename/RnExpr.lhs @@ -111,8 +111,7 @@ rnExpr (HsVar v) finishHsVar name rnExpr (HsIPVar v) - = do v' <- rnIPName v - return (HsIPVar v', emptyFVs) + = return (HsIPVar v, emptyFVs) rnExpr (HsLit lit@(HsString s)) = do { diff --git a/compiler/rename/RnTypes.lhs b/compiler/rename/RnTypes.lhs index ecdfdaf36e..ed2144084a 100644 --- a/compiler/rename/RnTypes.lhs +++ b/compiler/rename/RnTypes.lhs @@ -16,7 +16,7 @@ module RnTypes ( rnHsType, rnLHsType, rnLHsTypes, rnContext, rnHsKind, rnLHsKind, rnLHsMaybeKind, rnHsSigType, rnLHsInstType, rnConDeclFields, - rnIPName, newTyVarNameRn, + newTyVarNameRn, -- Precence related stuff mkOpAppRn, mkNegAppRn, mkOpFormRn, mkConOpPatRn, @@ -41,7 +41,6 @@ import HsSyn import RnHsDoc ( rnLHsDoc, rnMbLHsDoc ) import RnEnv import TcRnMonad -import IfaceEnv ( newIPName ) import RdrName import PrelNames import TysPrim ( funTyConName ) @@ -50,7 +49,7 @@ import SrcLoc import NameSet import Util -import BasicTypes ( IPName(..), ipNameName, compareFixity, funTyFixity, negateFixity, +import BasicTypes ( compareFixity, funTyFixity, negateFixity, Fixity(..), FixityDirection(..) ) import Outputable import FastString @@ -248,8 +247,7 @@ rnHsTyKi isType doc (HsAppTy ty1 ty2) rnHsTyKi isType doc (HsIParamTy n ty) = ASSERT( isType ) do { (ty', fvs) <- rnLHsType doc ty - ; n' <- rnIPName n - ; return (HsIParamTy n' ty', fvs) } + ; return (HsIParamTy n ty', fvs) } rnHsTyKi isType doc (HsEqTy ty1 ty2) = ASSERT( isType ) @@ -494,9 +492,6 @@ rnContext :: HsDocContext -> LHsContext RdrName -> RnM (LHsContext Name, FreeVar rnContext doc (L loc cxt) = do { (cxt', fvs) <- rnLHsTypes doc cxt ; return (L loc cxt', fvs) } - -rnIPName :: IPName RdrName -> RnM (IPName Name) -rnIPName n = newIPName (occNameFS (rdrNameOcc (ipNameName n))) \end{code} |
