From 37e9215f270f097cf914fe6845cd27cddb10de1b Mon Sep 17 00:00:00 2001 From: David Waern Date: Wed, 22 Oct 2008 21:17:29 +0000 Subject: Fix warnings in H.GHC.Utils --- src/Haddock/GHC/Utils.hs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/Haddock/GHC') diff --git a/src/Haddock/GHC/Utils.hs b/src/Haddock/GHC/Utils.hs index 549482ef..40e13004 100644 --- a/src/Haddock/GHC/Utils.hs +++ b/src/Haddock/GHC/Utils.hs @@ -81,23 +81,28 @@ getMainDeclBinder (ForD (ForeignExport _ _ _)) = Nothing getMainDeclBinder _ = Nothing +isTyClD :: HsDecl a -> Bool isTyClD (TyClD _) = True isTyClD _ = False +isClassD :: HsDecl a -> Bool isClassD (TyClD d) = isClassDecl d isClassD _ = False +isDocD :: HsDecl a -> Bool isDocD (DocD _) = True isDocD _ = False +isInstD :: HsDecl a -> Bool isInstD (InstD _) = True isInstD (TyClD d) = isFamInstDecl d isInstD _ = False +declATs :: HsDecl a -> [a] declATs (TyClD d) | isClassDecl d = map (tcdName . unL) $ tcdATs d declATs _ = [] -- cgit v1.2.3