fork download
  1. import Data.Typeable
  2.  
  3. getStaticType :: Typeable a => a -> String
  4. getStaticType = show . typeOf
  5.  
  6. main = do
  7. putStr(getStaticType(x))
  8. where
  9. x = 42 deriving Typeable
  10.  
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
[1 of 1] Compiling Main             ( prog.hs, prog.o )

prog.hs:9:12: parse error on input `deriving'
stdout
Standard output is empty