401b44ac1b
The default Generics-based ToSample instance now uses Omega type to productively produce distinct samples. The previous version was based on lists and hence left-recursive. This means that with previous versions the default toSamples for [Bool] would return an infinite list like this: [[],[False],[False,False],[False,False,False],... As you can see it would never produce a list with True in it. Omega handles this and produces a more diverse output: [[],[False],[False,False],[True],... This is still not the best possible case, but to do better we need to use Omega not only in GToSample, but in ToSample as well since GToSample uses ToSample instances recursively. |
||
---|---|---|
.. | ||
Servant |