projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
A little refactoring, plus improve error locations
[ghc-hetmet.git]
/
compiler
/
typecheck
/
TcDeriv.lhs
diff --git
a/compiler/typecheck/TcDeriv.lhs
b/compiler/typecheck/TcDeriv.lhs
index
3466cbf
..
5d2b829
100644
(file)
--- a/
compiler/typecheck/TcDeriv.lhs
+++ b/
compiler/typecheck/TcDeriv.lhs
@@
-440,8
+440,7
@@
deriveStandalone (L loc (DerivDecl deriv_ty))
<+> text "tvs:" <+> ppr tvs
<+> text "theta:" <+> ppr theta
<+> text "tau:" <+> ppr tau)
<+> text "tvs:" <+> ppr tvs
<+> text "theta:" <+> ppr theta
<+> text "tau:" <+> ppr tau)
- ; (cls, inst_tys) <- checkValidInstHead tau
- ; checkValidInstance tvs theta cls inst_tys
+ ; (cls, inst_tys) <- checkValidInstance deriv_ty tvs theta tau
-- C.f. TcInstDcls.tcLocalInstDecl1
; let cls_tys = take (length inst_tys - 1) inst_tys
-- C.f. TcInstDcls.tcLocalInstDecl1
; let cls_tys = take (length inst_tys - 1) inst_tys