Ticket #786: Unboxable3.hs

File Unboxable3.hs, 218 bytes (added by guest, 9 years ago)
Line 
1{-# OPTIONS_GHC -fglasgow-exts #-}
2import GHC.Base
3class Unboxable value where
4    readUnboxable  :: Int -> value
5instance Unboxable Int where
6    readUnboxable (I# value#) =  tagToEnum# value#
7main = return ()