
1 Jul
2011
1 Jul
'11
4:08 a.m.
On Friday 01 July 2011, 09:55:40, Ivan Lazar Miljenovic wrote:
I propose we add a operator - tentatively labelled $!! (and which Hayoo reports isn't currently exported by a Hackage package) - as a deepseq analogue $! to the deepseq library:
($!!) :: (NFData a) => (a -> b) ->a -> b f $!! x = x `deepseq` f x
infixr 0 $!!
I think that would be useful.
As a sub-proposal, I also propose that we add a "force" function (the name of which also seems to be unused) to make it easier to test forcing of values:
force :: (NFData a) => a -> a force x = x `deepseq` x
Could also be useful.
Discussion time: 2 weeks
+1