diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2012-03-02 16:36:41 +0000 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2012-03-02 16:36:41 +0000 |
commit | 833e6de190eab5c1b2cc856ccc3c7edbbdbe4b0f (patch) | |
tree | 24bfc488236e83cbdf5543046a841d315aa0c5e8 /src/Haddock/Interface/Rename.hs | |
parent | 53a15353b9521a049cb9bbc033acd3654a52033f (diff) |
Follow changes in data representation from the big PolyKinds commit
Diffstat (limited to 'src/Haddock/Interface/Rename.hs')
-rw-r--r-- | src/Haddock/Interface/Rename.hs | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/Haddock/Interface/Rename.hs b/src/Haddock/Interface/Rename.hs index 670fa9cf..a295fe29 100644 --- a/src/Haddock/Interface/Rename.hs +++ b/src/Haddock/Interface/Rename.hs @@ -260,11 +260,13 @@ renameType t = case t of renameLTyVarBndr :: LHsTyVarBndr Name -> RnM (LHsTyVarBndr DocName) -renameLTyVarBndr (L loc tv) = do - name' <- rename (hsTyVarName tv) - tyvar' <- replaceTyVarName tv name' renameLKind - return $ L loc tyvar' - +renameLTyVarBndr (L loc (UserTyVar n tck)) + = do { n' <- rename n + ; return (L loc (UserTyVar n' tck)) } +renameLTyVarBndr (L loc (KindedTyVar n (HsBSig k fvs) tck)) + = do { n' <- rename n + ; k' <- renameLKind k + ; return (L loc (KindedTyVar n' (HsBSig k' fvs) tck)) } renameLContext :: Located [LHsType Name] -> RnM (Located [LHsType DocName]) renameLContext (L loc context) = do @@ -330,12 +332,12 @@ renameTyClD d = case d of -- I don't think we need the derivings, so we return Nothing return (TyData x lcontext' lname' cType ltyvars' typats' k' cons' Nothing) - TySynonym lname ltyvars typats ltype -> do + TySynonym lname ltyvars typats ltype fvs -> do lname' <- renameL lname ltyvars' <- mapM renameLTyVarBndr ltyvars ltype' <- renameLType ltype typats' <- mapM (mapM renameLType) typats - return (TySynonym lname' ltyvars' typats' ltype') + return (TySynonym lname' ltyvars' typats' ltype' fvs) ClassDecl lcontext lname ltyvars lfundeps lsigs _ ats at_defs _ -> do lcontext' <- renameLContext lcontext |