Skip to content

Commit

Permalink
Fix warnings in prelude/ForeignCall.lhs
Browse files Browse the repository at this point in the history
  • Loading branch information
igfoo committed Oct 2, 2011
1 parent 1a97815 commit 48a5c1e
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions compiler/prelude/ForeignCall.lhs
Expand Up @@ -4,12 +4,6 @@
\section[Foreign]{Foreign calls} \section[Foreign]{Foreign calls}


\begin{code} \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
{-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveDataTypeable #-}
module ForeignCall ( module ForeignCall (
Expand Down Expand Up @@ -173,6 +167,8 @@ defaultCCallConv = CCallConv
ccallConvToInt :: CCallConv -> Int ccallConvToInt :: CCallConv -> Int
ccallConvToInt StdCallConv = 0 ccallConvToInt StdCallConv = 0
ccallConvToInt CCallConv = 1 ccallConvToInt CCallConv = 1
ccallConvToInt (CmmCallConv {}) = panic "ccallConvToInt CmmCallConv"
ccallConvToInt (PrimCallConv {}) = panic "ccallConvToInt PrimCallConv"
\end{code} \end{code}


Generate the gcc attribute corresponding to the given Generate the gcc attribute corresponding to the given
Expand All @@ -182,6 +178,8 @@ calling convention (used by PprAbsC):
ccallConvAttribute :: CCallConv -> String ccallConvAttribute :: CCallConv -> String
ccallConvAttribute StdCallConv = "__attribute__((__stdcall__))" ccallConvAttribute StdCallConv = "__attribute__((__stdcall__))"
ccallConvAttribute CCallConv = "" ccallConvAttribute CCallConv = ""
ccallConvAttribute (CmmCallConv {}) = panic "ccallConvAttribute CmmCallConv"
ccallConvAttribute (PrimCallConv {}) = panic "ccallConvAttribute PrimCallConv"
\end{code} \end{code}


\begin{code} \begin{code}
Expand Down

0 comments on commit 48a5c1e

Please sign in to comment.