Skip to content

Commit

Permalink
Compatibility with ghc head
Browse files Browse the repository at this point in the history
  • Loading branch information
markwright committed Jun 30, 2012
1 parent 9a0268f commit e25f69d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
2 changes: 2 additions & 0 deletions Network/BSD.hsc
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ import Foreign.Storable (Storable(..))
import Foreign.Marshal.Array (allocaArray0, peekArray0)
import Foreign.Marshal.Utils (with, fromBool)
import Data.Typeable
#if !MIN_VERSION_base(4,6,0)
import Prelude hiding (catch)
#endif
import System.IO.Error (ioeSetErrorString, mkIOError)
import System.IO.Unsafe (unsafePerformIO)

Expand Down
12 changes: 6 additions & 6 deletions network.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ library
Network.Socket.ByteString.MsgHdr

build-depends:
base >= 3 && < 4.6,
base >= 3 && < 4.7,
bytestring < 1.0,
parsec >= 2.0 && < 3.2

Expand All @@ -62,11 +62,11 @@ test-suite simple
type: exitcode-stdio-1.0

build-depends:
base < 4.6,
bytestring < 0.10,
base < 4.7,
bytestring < 1.0,
HUnit < 1.3,
network,
test-framework < 0.6,
test-framework < 0.7,
test-framework-hunit < 0.3

test-suite uri
Expand All @@ -75,10 +75,10 @@ test-suite uri
type: exitcode-stdio-1.0

build-depends:
base < 4.6,
base < 4.7,
HUnit < 1.3,
network,
test-framework < 0.6,
test-framework < 0.7,
test-framework-hunit < 0.3

source-repository head
Expand Down
4 changes: 3 additions & 1 deletion tests/Simple.hs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE CPP, ScopedTypeVariables #-}
{-# OPTIONS_GHC -fno-warn-unused-do-bind #-}

module Main where
Expand All @@ -10,7 +10,9 @@ import qualified Data.ByteString as S
import qualified Data.ByteString.Char8 as C
import Network.Socket hiding (recv, recvFrom, send, sendTo)
import Network.Socket.ByteString
#if !MIN_VERSION_base(4,6,0)
import Prelude hiding (catch)
#endif
import Test.Framework (Test, defaultMain, testGroup)
import Test.Framework.Providers.HUnit (testCase)
import Test.HUnit (Assertion, (@=?))
Expand Down

0 comments on commit e25f69d

Please sign in to comment.