
23 Sep
2009
23 Sep
'09
11:52 a.m.
Roel van Dijk
I would like some feedback on the instances for STRef and IORef. Does it make sense to have them? I used a trick to force their evaluation since their constructors are not exported.
This might be "dirty" but what about this instead?
instance (NFData a) => NFData (Data.IORef.IORef a) where
rnf r = unsafePerformIO $ modifyIORef r (`using` rnf)
G.
--
Gregory Collins