Kind error in GHC-7.4.1, works in GHC-7.2.2

Roel van Dijk vandijk.roel at gmail.com
Sun Feb 12 16:58:58 CET 2012


Thank you for the explanation. I now understand the problem. I have
rewritten the code using some parenthesis.

Thanks,
Roel

2012/2/10 Simon Peyton-Jones <simonpj at microsoft.com>:
> It should not have worked before.  Consider
>
>        I#  $   3#
>
> ($) is a polymorphic function and takes two *pointer* arguments.  If we actually called it with I# and 3# as arguments we might seg-fault when we call the GC when allocating the box.
>
> Polymorphic type variables (in this case in the type of ($)) can only be instantiated with boxed types.
>
> Simon



More information about the Glasgow-haskell-users mailing list