[project @ 2003-02-14 14:22:24 by simonpj]
authorsimonpj <unknown>
Fri, 14 Feb 2003 14:22:25 +0000 (14:22 +0000)
committersimonpj <unknown>
Fri, 14 Feb 2003 14:22:25 +0000 (14:22 +0000)
commit5538aeebb0a92ec73552d92df3afbb70612ca56d
treef4d11d25b4b357f09e6eac2178cbabc20a922d28
parent580b4fe61a48c95699e57c73e5502b88b6d315d5
[project @ 2003-02-14 14:22:24 by simonpj]
-------------------------------------
   Do the top-level tcSimpifyTop (to resolve monomorphic constraints)
   once for the whole program, rather than once per splice group
-------------------------------------

This change makes the trivial program

main = return ()

work again.  It had stopped working (emitting an error about Monad m
being unconstrained) because the 'checkMain' stuff (which knows special
things about 'main' was happening only *after* all the groups of
decls in the module had been dealt with and zonked (incl tcSimplifyTop).

Better to postpone.  A little more plumbing, but one fewer unexpected
happenings.
ghc/compiler/typecheck/TcHsSyn.lhs
ghc/compiler/typecheck/TcRnDriver.lhs
ghc/compiler/typecheck/TcRnMonad.lhs
ghc/compiler/typecheck/TcRnTypes.lhs