X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fprelude%2FForeignCall.lhs;h=50130785cd72a9e608403f2452766a2fd8a32b69;hp=2c90a7dc6ea447880de1032d369fa77be89e04a0;hb=30c122df62ec75f9ed7f392f24c2925675bf1d06;hpb=0065d5ab628975892cea1ec7303f968c3338cbe1 diff --git a/compiler/prelude/ForeignCall.lhs b/compiler/prelude/ForeignCall.lhs index 2c90a7d..5013078 100644 --- a/compiler/prelude/ForeignCall.lhs +++ b/compiler/prelude/ForeignCall.lhs @@ -4,6 +4,13 @@ \section[Foreign]{Foreign calls} \begin{code} +{-# OPTIONS -w #-} +-- The above warning supression flag is a temporary kludge. +-- While working on this module you are encouraged to remove it and fix +-- any warnings in the module. See +-- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#Warnings +-- for details + module ForeignCall ( ForeignCall(..), Safety(..), playSafe, playThreadSafe, @@ -19,7 +26,7 @@ module ForeignCall ( #include "HsVersions.h" -import FastString ( FastString, unpackFS ) +import FastString import Char ( isAlphaNum ) import Binary import Outputable @@ -128,13 +135,14 @@ so perhaps we should emit a warning if it's being used on other platforms. \begin{code} -data CCallConv = CCallConv | StdCallConv +data CCallConv = CCallConv | StdCallConv | CmmCallConv deriving (Eq) {-! derive: Binary !-} instance Outputable CCallConv where ppr StdCallConv = ptext SLIT("stdcall") ppr CCallConv = ptext SLIT("ccall") + ppr CmmCallConv = ptext SLIT("C--") defaultCCallConv :: CCallConv defaultCCallConv = CCallConv