packages feed

smallcheck 0.6 → 0.6.1

raw patch · 3 files changed

+47/−2 lines, 3 files

Files

CHANGES.md view
@@ -1,6 +1,12 @@ Changes ======= +Version 0.6.1+-----------++* Documentation improvements+* Make the package build with GHC 7.4.1+ Version 0.6 ----------- 
Test/SmallCheck/Series.hs view
@@ -50,6 +50,21 @@   --   -- The depth of @Light x@ is just the depth of @x@. +  -- ** What does consN do, exactly?++  -- | @consN@ has type+  -- @(Serial t_1, ..., Serial t_N) => (t_1 -> ... -> t_N -> t) -> Series t@.+  --+  -- @consN f@ is a series which, for a given depth @d > 0@, produces values of the+  -- form+  --+  -- >f x_1 ... x_N+  --+  -- where @x_i@ ranges over all values of type @t_i@ of depth up to @d-1@+  -- (as defined by the 'series' functions for @t_i@).+  --+  -- If @d <= 0@, no values are produced.+   cons0, cons1, cons2, cons3, cons4,   -- * Function Generators @@ -67,6 +82,23 @@   -- >coseries rs d = [ \l -> case l of   -- >                        Light x -> f x   -- >                |  f <- (alts1 rs . depth 0) d ]++  -- ** What does altsN do, exactly?++  -- | @altsN@ has type+  -- @(Serial t_1, ..., Serial t_N) => Series t -> Series (t_1 -> ... -> t_N -> t)@.+  --+  -- @altsN s@ is a series which, for a given depth @d@, produces functions of+  -- type+  --+  -- >t_1 -> ... -> t_N -> t+  --+  -- If @d <= 0@, these are constant functions, one for each value of @s 0@.+  --+  -- If @d > 0@, these functions inspect each of their arguments up to depth+  -- @d-1@ (as defined by the 'coseries' functions for the corresponding+  -- types) and return values given by @s d@.+   alts0, alts1, alts2, alts3, alts4,    -- * Automated Derivation of Generators@@ -121,6 +153,10 @@ type Depth = Int  -- | 'Series' is a function from the depth to a finite list of values.+--+-- If @s@ is a 'Series', @s n@ is expected to yield values of depth up to @n@.+--+-- (In particular, @series d@ is expected to be a subset of @series (d+1)@.) type Series a = Depth -> [a]  -- | Sum (union) of series@@ -135,6 +171,9 @@  class Serial a where   series   :: Series a+  -- | A proper 'coseries' implementation should pass the depth unchanged to+  -- its first argument. Doing otherwise will make enumeration of curried+  -- functions non-uniform in their arguments.   coseries :: Series b -> Series (a->b)  #ifdef GENERICS
smallcheck.cabal view
@@ -1,5 +1,5 @@ Name:          smallcheck-Version:       0.6+Version:       0.6.1 Cabal-Version: >= 1.6 License:       BSD3 License-File:  LICENSE@@ -39,7 +39,7 @@ Source-repository this   type:     git   location: git://github.com/feuerbach/smallcheck.git-  tag:      v0.6+  tag:      v0.6.1  Library