Make do-notation a bit more flexible (Trac #1537)
authorsimonpj@microsoft.com <unknown>
Tue, 5 Feb 2008 16:48:16 +0000 (16:48 +0000)
committersimonpj@microsoft.com <unknown>
Tue, 5 Feb 2008 16:48:16 +0000 (16:48 +0000)
commitbddd4b23e32532091a64bdb1c432dfbc8ca84645
tree789c20e77769b46df218bf6c676aa3baba444482
parentdf61ac588d1e7132acea67596ca3d735a308eafb
Make do-notation a bit more flexible (Trac #1537)

This is a second attempt to fix #1537: to make the static typechecking
of do-notation behave just like the desugared version of the same thing.
This should allow parameterised monads to work properly (see Oleg's comment
in the above ticket).

We can probably merge to 6.8.3 if it goes smoothly.

Incidentally, the resulting setup suffers from greater type ambiguity
if (>>=) has a very general type.  So test rebindable6 no longer works
(at least not without more type signatures), and rebindable5 requires
extra functional dependencies.  But they are weird tests.
compiler/deSugar/DsExpr.lhs
compiler/typecheck/TcMatches.lhs