Package for QuickCheck instances

Nick Smallbone nicsma at chalmers.se
Tue Jan 10 18:40:00 GMT 2012


Hi Antoine,

This is great, thanks! I've applied the patch you sent me with the
instances for Ordering and Fixed a, and added arbitraryBoundedEnum.
They should make their way into the next release.

As to what to do about the other instances, I'm not sure. It doesn't
seem sensible to put all of them in the QuickCheck package itself---it
will prevent the maintainers of e.g. ByteString and Text from writing
their own Arbitrary instances. I think I'll ask on the libraries list
for advice. Maybe having them in a separate package like you have is
the best approach.

Nick

On 3 January 2012 02:32, Antoine Latter <aslatter at gmail.com> wrote:
> Hi QuickCheck,
>
> I was writing some tests that involved a large number of quickcheck
> properties which don't ship with the library itself, so I thought I
> would package them all together and put the orphan instances on
> Hackage. Here's what I have so far:
>
> https://github.com/aslatter/qc-instances/tree/f68cb8398b7fa6b40b382a714292832d515ed389
>
> The policy would be to allow anything into to package which is a part
> of the Haskell Platform or is a GHC build library.
>
> Has anyone already done this? I didn't find anything from grepping the
> Hackage package list.
>
> Has anyone already talked about doing this sort of thing? Are their
> any non-obvious pitfalls (aside from the package eventually becoming a
> cesspool of CPP conditions)?
>
> Thanks,
> Antoine
>
> _______________________________________________
> QuickCheck mailing list
> QuickCheck at projects.haskell.org
> http://projects.haskell.org/cgi-bin/mailman/listinfo/quickcheck



More information about the QuickCheck mailing list