proposal: add 'unsafeCoerce'

John Meacham john at
Sun Nov 19 14:46:32 EST 2006

On Sun, Nov 19, 2006 at 01:30:16PM +0000, Neil Mitchell wrote:
> Yhc translates Haskell to a well-typed (using rank-2 types, but not
> explicitly typed) language. To translate this language back to Haskell
> requires type annotations (which were lost ages ago), or lots of
> unsafeCoerce, which is the significantly easier method. In practice
> the unsafeCoerce's have never gone wrong on any compiler.

This is what jhc does when compiling via ghc as well.


John Meacham - ⑆⑆john⑈

More information about the Libraries mailing list