projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Extended TyCon and friends to represent family declarations
[ghc-hetmet.git]
/
compiler
/
typecheck
/
TcClassDcl.lhs
diff --git
a/compiler/typecheck/TcClassDcl.lhs
b/compiler/typecheck/TcClassDcl.lhs
index
25795ce
..
9fb530d
100644
(file)
--- a/
compiler/typecheck/TcClassDcl.lhs
+++ b/
compiler/typecheck/TcClassDcl.lhs
@@
-739,8
+739,12
@@
tcAddDeclCtxt decl thing_inside
thing = case decl of
ClassDecl {} -> "class"
TySynonym {} -> "type synonym"
thing = case decl of
ClassDecl {} -> "class"
TySynonym {} -> "type synonym"
- TyData {tcdND = NewType} -> "newtype"
- TyData {tcdND = DataType} -> "data type"
+ TyFunction {} -> "type function signature"
+ TyData {tcdND = NewType} -> "newtype" ++ maybeSig
+ TyData {tcdND = DataType} -> "data type" ++ maybeSig
+
+ maybeSig | isKindSigDecl decl = " signature"
+ | otherwise = ""
ctxt = hsep [ptext SLIT("In the"), text thing,
ptext SLIT("declaration for"), quotes (ppr (tcdName decl))]
ctxt = hsep [ptext SLIT("In the"), text thing,
ptext SLIT("declaration for"), quotes (ppr (tcdName decl))]