The trouble is that *any* function can now deliver unpredictable
results. Can I rely on the fact that
foo :: Int - Int
will always give the same answer given the same input. Not any more.
I think the strongest argument here is that it's like a more benign
version of unsafePerformIO,
Simon Peyton-Jones wrote:
The trouble is that *any* function can now deliver unpredictable
results. Can I rely on the fact that
foo :: Int - Int
will always give the same answer given the same input. Not any more.
Yes, I see what you mean.
I think the strongest argument here is that it's
George Russell wrote:
Simon Peyton-Jones wrote:
The trouble is that *any* function can now deliver unpredictable
results. Can I rely on the fact that
foo :: Int - Int
will always give the same answer given the same input. Not any more.
Yes, I see what you mean.
I think the strongest
(me)
I suggest you implement
hashTypeable :: Typeable - IO Int32
Lennart wrote (snipped)
And/or
mkHashTypeable :: IO (Typeable - Int32)
Although this is OK, a general hash function might well need
to return IO HashKey.
A while back, before Data.Unique, I implemented a Unique module
with