packages feed

text-show 0.8 → 0.8.1

raw patch · 2 files changed

+15/−3 lines, 2 filesdep ~text-show

Dependency ranges changed: text-show

Files

tests/Instances/Numeric/Natural.hs view
@@ -13,11 +13,23 @@ -} module Instances.Numeric.Natural () where +-- Copied from @QuickCheck@+ #if !(MIN_VERSION_QuickCheck(2,8,0)) || !(MIN_VERSION_base(4,8,0)) import Numeric.Natural (Natural)-import Test.QuickCheck (Arbitrary(..), arbitrarySizedNatural, shrinkIntegral)+import Test.QuickCheck (Arbitrary(..), Gen,+                        choose, shrinkIntegral, sized, suchThat)  instance Arbitrary Natural where     arbitrary = arbitrarySizedNatural     shrink    = shrinkIntegral++-- | Generates a natural number. The number's maximum value depends on+-- the size parameter.+arbitrarySizedNatural :: Integral a => Gen a+arbitrarySizedNatural = sized $ \n ->+    inBounds fromInteger (choose (0, toInteger n))++inBounds :: Integral a => (Integer -> a) -> Gen Integer -> Gen a+inBounds fi g = fmap fi (g `suchThat` (\x -> toInteger (fi x) == x)) #endif
text-show.cabal view
@@ -1,5 +1,5 @@ name:                text-show-version:             0.8+version:             0.8.1 synopsis:            Efficient conversion of values into Text description:         @text-show@ offers a replacement for the @Show@ typeclass intended                      for use with @Text@ instead of @String@s. This package was created@@ -302,7 +302,7 @@                      -- , silently             >= 1.2.4 && < 1.3                      , tagged               >= 0.4.4  && < 1                      , text                 >= 0.11.1 && < 1.3-                     , text-show            == 0.8+                     , text-show            == 0.8.1                      , transformers         >= 0.2.1  && < 0.5                      , transformers-compat  >= 0.3    && < 1                      , void                 >= 0.5    && < 1