[Haskell-cafe] Re: instance Eq (a -> b)

Ashley Yakeley ashley at semantic.org
Wed Apr 14 04:31:42 EDT 2010


On Wed, 2010-04-14 at 09:29 +0100, Thomas Davie wrote:
> It isn't?
> 
> fPrelude> fmap id (undefined :: IO ())
> *** Exception: Prelude.undefined

ghci is helpfully running the IO action for you. Try this:

 seq (fmap id (undefined :: IO ())) "not bottom"

-- 
Ashley Yakeley



More information about the Haskell-Cafe mailing list