If I define
{-# LANGUAGE MagicHash #-}
g :: Int# -> Int
g 3# = 3
myUndefined = undefined
then this gives a sensible type error about a kind mismatch:
usual :: Int
usual = g myUndefined
but this, oddly enough, compiles:
peculiar :: Int
peculiar = g undefined
GHCi and the definition in GHC.Error agree that
undefined :: a
So why am I allowed to use it as a type of kind #?
_______________________________________________
ghc-devs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/ghc-devs