diff options
author | David Waern <david.waern@gmail.com> | 2008-08-12 22:49:57 +0000 |
---|---|---|
committer | David Waern <david.waern@gmail.com> | 2008-08-12 22:49:57 +0000 |
commit | 20ee83c9b4134c90706a9a07f8267e40ab6c7057 (patch) | |
tree | 148be85888d154df4ef7af7add9a53dff04fdbb5 | |
parent | 85a778825b364145f368c419fc3ea3d7da06ed93 (diff) |
Remove matching on NoteTy in AttachInstances, it has been removed
-rw-r--r-- | src/Haddock/Interface/AttachInstances.hs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/Haddock/Interface/AttachInstances.hs b/src/Haddock/Interface/AttachInstances.hs index 782bee84..636a5149 100644 --- a/src/Haddock/Interface/AttachInstances.hs +++ b/src/Haddock/Interface/AttachInstances.hs @@ -78,6 +78,7 @@ collectInstances modules filterNames Just tycon <- nub (is_tcs inst) ] +-- TODO: should we support PredTy here? instHead :: ([TyVar], [PredType], Class, [Type]) -> ([Int], Name, [SimpleType]) instHead (_, _, cls, args) = (map argCount args, className cls, map simplify args) @@ -86,7 +87,6 @@ instHead (_, _, cls, args) argCount (TyConApp _ ts) = length ts argCount (FunTy _ _ ) = 2 argCount (ForAllTy _ t) = argCount t - argCount (NoteTy _ t) = argCount t argCount _ = 0 simplify (ForAllTy _ t) = simplify t @@ -96,7 +96,6 @@ instHead (_, _, cls, args) where (SimpleType s args) = simplify t1 simplify (TyVarTy v) = SimpleType (tyVarName v) [] simplify (TyConApp tc ts) = SimpleType (tyConName tc) (map simplify ts) - simplify (NoteTy _ t) = simplify t simplify _ = error "simplify" @@ -145,7 +144,6 @@ toHsType t = case t of FunTy a b -> HsFunTy (toLHsType a) (toLHsType b) ForAllTy v t -> cvForAll [v] t PredTy p -> HsPredTy (toHsPred p) - NoteTy _ t -> toHsType t where tycon tc = HsTyVar (tyConName tc) app tc ts = foldl (\a b -> HsAppTy (noLoc a) (noLoc b)) tc (map toHsType ts) |