RE: Strictness of addition functions.

15 Mar
2002
15 Mar
'02
3:38 a.m.
| data Pair = Pair !Int# !Int# | | f (Pair x y) = x +# y | | I still discovered to my dismay that the type of the first | argument to f is U(LL). | | What can I do to force the arguments to be strict? Int# is *always* strict. You don't need the !'s. The L is misleading, I suppose. But since Int# means *unboxed* 32-bit integers, there is simply no way you can pass a thunk. Simon
8468
Age (days ago)
8468
Last active (days ago)
0 comments
1 participants
participants (1)
-
Simon Peyton-Jones