[Haskell-cafe] Re: Efficient or predictable Ord for Typeable
lennart at augustsson.net
Tue Nov 30 07:11:27 EST 2004
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 argument here is that it's like a more benign
>> version of unsafePerformIO, whose existence also threatens foo's
> I suggest you implement
> hashTypeable :: Typeable -> IO Int32
mkHashTypeable :: IO (Typeable -> Int32)
More information about the Haskell-Cafe