diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2012-02-06 09:14:41 +0000 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2012-02-06 09:14:41 +0000 |
commit | 826c95646493284ab3c7c07ba159e959c760983c (patch) | |
tree | 1d2cacd5b55dc993137433da9c4c7e9d4e5603ec /src/Haddock/Interface/Create.hs | |
parent | 57491ab4ac6263d9d9a11e972e7a95c840c299de (diff) |
Track changes in HsDecls
Diffstat (limited to 'src/Haddock/Interface/Create.hs')
-rw-r--r-- | src/Haddock/Interface/Create.hs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Haddock/Interface/Create.hs b/src/Haddock/Interface/Create.hs index e51c8367..7e9b6a2b 100644 --- a/src/Haddock/Interface/Create.hs +++ b/src/Haddock/Interface/Create.hs @@ -189,7 +189,7 @@ mkMaps dflags gre instances exports decls = do let subNames = map fst subDocs let names = case d of - InstD (InstDecl (L l _) _ _ _) -> maybeToList (M.lookup l instanceMap) -- See note [2]. + InstD (ClsInstDecl (L l _) _ _ _) -> maybeToList (M.lookup l instanceMap) -- See note [2]. _ -> filter (`elem` exports) (getMainDeclBinder d) let docMap' = M.fromList (mapMaybe (\(n,doc) -> fmap (n,) doc) ([ (n, mayDoc) | n <- names ] ++ subDocs)) @@ -296,7 +296,7 @@ warnAboutFilteredDecls :: Module -> [LHsDecl Name] -> ErrMsgM () warnAboutFilteredDecls mdl decls = do let modStr = moduleString mdl let typeInstances = - nub [ tcdName d | L _ (TyClD d) <- decls, isFamInstDecl d ] + nub [ tcdName d | L _ (InstD (FamInstDecl d)) <- decls ] unless (null typeInstances) $ tell [ @@ -305,7 +305,7 @@ warnAboutFilteredDecls mdl decls = do ++ "will be filtered out:\n " ++ concat (intersperse ", " $ map (occNameString . nameOccName) typeInstances) ] - let instances = nub [ pretty i | L _ (InstD (InstDecl i _ _ ats)) <- decls + let instances = nub [ pretty i | L _ (InstD (ClsInstDecl i _ _ ats)) <- decls , not (null ats) ] unless (null instances) $ |