Fix another fundep error (fixes Trac #4969)
authorsimonpj@microsoft.com <unknown>
Mon, 21 Feb 2011 15:32:39 +0000 (15:32 +0000)
committersimonpj@microsoft.com <unknown>
Mon, 21 Feb 2011 15:32:39 +0000 (15:32 +0000)
commitd1796b5266121ff6930d6cabba6201e48708703b
tree13b49756d20282fdc948ee0e5cecc68bffd1ca83
parent4c53d93a7690b89b44f6d52380de867527800924
Fix another fundep error (fixes Trac #4969)

If I had a pound for every hour Dimitrios and I have spent
making functional dependencies work right, we'd be rich!

We had stupidly caused a 'wanted' to be rewritten by a 'derived', with
resulting abject failure.  As well as fixing the bug, this patch
refactors some more, adds useful assert and comments.
compiler/typecheck/TcCanonical.lhs
compiler/typecheck/TcInteract.lhs
compiler/typecheck/TcMType.lhs
compiler/typecheck/TcSMonad.lhs
compiler/typecheck/TcSimplify.lhs
compiler/typecheck/TcUnify.lhs