projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
9b58234
)
Improve typechecker error messages; see Trac #1221
author
simonpj@microsoft.com
<unknown>
Wed, 14 Mar 2007 12:14:10 +0000
(12:14 +0000)
committer
simonpj@microsoft.com
<unknown>
Wed, 14 Mar 2007 12:14:10 +0000
(12:14 +0000)
compiler/typecheck/TcUnify.lhs
patch
|
blob
|
history
diff --git
a/compiler/typecheck/TcUnify.lhs
b/compiler/typecheck/TcUnify.lhs
index
99cd7b9
..
8de9f6c
100644
(file)
--- a/
compiler/typecheck/TcUnify.lhs
+++ b/
compiler/typecheck/TcUnify.lhs
@@
-721,8
+721,12
@@
tc_sub1 sub_ctxt act_sty actual_ty exp_ib exp_sty expected_ty
-----------------------------------
defer_to_boxy_matching sub_ctxt act_sty actual_ty exp_ib exp_sty expected_ty
= do { addSubCtxt sub_ctxt act_sty exp_sty $
-----------------------------------
defer_to_boxy_matching sub_ctxt act_sty actual_ty exp_ib exp_sty expected_ty
= do { addSubCtxt sub_ctxt act_sty exp_sty $
- u_tys True False act_sty actual_ty exp_ib exp_sty expected_ty
+ u_tys outer False act_sty actual_ty exp_ib exp_sty expected_ty
; return idHsWrapper }
; return idHsWrapper }
+ where
+ outer = case sub_ctxt of -- Ugh
+ SubDone -> False
+ other -> True
-----------------------------------
tc_sub_funs act_arg act_res exp_ib exp_arg exp_res
-----------------------------------
tc_sub_funs act_arg act_res exp_ib exp_arg exp_res