Add mkHsCoerce to avoid junk in typechecked code
authorsimonpj@microsoft.com <unknown>
Mon, 30 Jan 2006 13:12:31 +0000 (13:12 +0000)
committersimonpj@microsoft.com <unknown>
Mon, 30 Jan 2006 13:12:31 +0000 (13:12 +0000)
commiteb57096f08bbccf59e6551b135fbde5ed22a0fa8
treebe0aa491f0d00242e261cb401ff64b8343d00676
parent4417e97d436e2796bed886cb1a830acb88d3da28
Add mkHsCoerce to avoid junk in typechecked code

Avoiding identity coercions is a Good Thing generally, but
it turns out that the desugarer has trouble recognising
'otherwise' and 'True' guards if they are wrapped in an
identity coercion; and that leads to bogus overlap warnings.
ghc/compiler/deSugar/DsGRHSs.lhs
ghc/compiler/hsSyn/HsUtils.lhs
ghc/compiler/typecheck/TcBinds.lhs
ghc/compiler/typecheck/TcExpr.lhs
ghc/compiler/typecheck/TcMatches.lhs