aboutsummaryrefslogtreecommitdiff
path: root/src/HaddockUtil.hs
diff options
context:
space:
mode:
authordavve <davve@dtek.chalmers.se>2006-07-29 16:16:43 +0000
committerdavve <davve@dtek.chalmers.se>2006-07-29 16:16:43 +0000
commit82a5bcbb729d769a53e9c14b0be9c9b6b8daa548 (patch)
tree5b322c70a0384bc2130c65e18bd0809d2a5e0712 /src/HaddockUtil.hs
parent6697b3f741f85b187e18cd9aeed658e974832b43 (diff)
Add instances, build renaming environment, start on the renamer
Diffstat (limited to 'src/HaddockUtil.hs')
-rw-r--r--src/HaddockUtil.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/HaddockUtil.hs b/src/HaddockUtil.hs
index 35290c27..7ce16cd3 100644
--- a/src/HaddockUtil.hs
+++ b/src/HaddockUtil.hs
@@ -143,8 +143,8 @@ addConDocs (x:xs) doc = addConDoc x doc : xs
-- ---------------------------------------------------------------------------
-- Making abstract declarations
-restrictTo :: [GHC.Name] -> (GHC.HsDecl GHC.Name) -> (GHC.HsDecl GHC.Name)
-restrictTo names decl = case decl of
+restrictTo :: [GHC.Name] -> (GHC.LHsDecl GHC.Name) -> (GHC.LHsDecl GHC.Name)
+restrictTo names (L loc decl) = L loc $ case decl of
GHC.TyClD d doc | GHC.isDataDecl d && GHC.tcdND d == GHC.DataType ->
GHC.TyClD (d { GHC.tcdCons = restrictCons names (GHC.tcdCons d) }) doc
GHC.TyClD d doc | GHC.isDataDecl d && GHC.tcdND d == GHC.NewType ->