X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fprelude%2FForeignCall.lhs;h=63c902963ba78cbca5c39bb40d784658421d7b54;hp=4423d0317cccb0bd5f5b7d0f2301bc38d25ee4ec;hb=f278f0676579f67075033a4f9857715909c4b71e;hpb=ef6e8211dee59eb7fa80a242391b89b52bd57f80 diff --git a/compiler/prelude/ForeignCall.lhs b/compiler/prelude/ForeignCall.lhs index 4423d03..63c9029 100644 --- a/compiler/prelude/ForeignCall.lhs +++ b/compiler/prelude/ForeignCall.lhs @@ -10,6 +10,7 @@ -- any warnings in the module. See -- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#Warnings -- for details +{-# LANGUAGE DeriveDataTypeable #-} module ForeignCall ( ForeignCall(..), @@ -27,6 +28,7 @@ import Outputable import Module import Data.Char +import Data.Data \end{code} @@ -63,7 +65,7 @@ data Safety | PlayRisky -- None of the above can happen; the call will return -- without interacting with the runtime system at all - deriving ( Eq, Show ) + deriving ( Eq, Show, Data, Typeable ) -- Show used just for Show Lex.Token, I think {-! derive: Binary !-} @@ -89,6 +91,7 @@ data CExportSpec = CExportStatic -- foreign export ccall foo :: ty CLabelString -- C Name of exported function CCallConv + deriving (Data, Typeable) {-! derive: Binary !-} data CCallSpec @@ -121,7 +124,7 @@ data CCallTarget -- Used when importing a label as "foreign import ccall "dynamic" ..." | DynamicTarget - deriving( Eq ) + deriving( Eq, Data, Typeable ) {-! derive: Binary !-} isDynamicTarget :: CCallTarget -> Bool @@ -146,7 +149,7 @@ See: http://www.programmersheaven.com/2/Calling-conventions \begin{code} data CCallConv = CCallConv | StdCallConv | CmmCallConv | PrimCallConv - deriving (Eq) + deriving (Eq, Data, Typeable) {-! derive: Binary !-} instance Outputable CCallConv where