[commit: bytestring] master: Allow using older versions of the random package (a1ac703)
Ian Lynagh
igloo at earth.li
Wed Feb 22 21:58:42 CET 2012
Repository : ssh://darcs.haskell.org//srv/darcs/packages/bytestring
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/a1ac70364a80d1423a83ee6f4d9422f2fd393b59
>---------------------------------------------------------------
commit a1ac70364a80d1423a83ee6f4d9422f2fd393b59
Author: Duncan Coutts <duncan at community.haskell.org>
Date: Thu Nov 17 01:11:28 2011 +0000
Allow using older versions of the random package
>---------------------------------------------------------------
bytestring.cabal | 2 +-
tests/QuickCheckUtils.hs | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/bytestring.cabal b/bytestring.cabal
index 0af5f2f..1075183 100644
--- a/bytestring.cabal
+++ b/bytestring.cabal
@@ -123,7 +123,7 @@ test-suite prop-compiled
type: exitcode-stdio-1.0
main-is: Properties.hs
hs-source-dirs: . tests
- build-depends: base, deepseq, random >= 1.0.1, directory,
+ build-depends: base, deepseq, random, directory,
QuickCheck >= 2.3 && < 3
if impl(ghc >= 6.10)
build-depends: ghc-prim
diff --git a/tests/QuickCheckUtils.hs b/tests/QuickCheckUtils.hs
index 7c781cf..959ea86 100644
--- a/tests/QuickCheckUtils.hs
+++ b/tests/QuickCheckUtils.hs
@@ -96,7 +96,8 @@ instance Arbitrary CByteString where
fromCChar = fromIntegral
instance Arbitrary CChar where
- arbitrary = oneof [choose (-128,-1), choose (1,127)]
+ arbitrary = fmap (fromIntegral :: Int -> CChar)
+ $ oneof [choose (-128,-1), choose (1,127)]
------------------------------------------------------------------------
--
More information about the Cvs-libraries
mailing list