Relax the restriction on Bounded derivation
isaacdupree at charter.net
Wed Apr 18 08:29:25 EDT 2007
-----BEGIN PGP SIGNED MESSAGE-----
Isaac Dupree wrote:
> However there is a good argument for having some sort of bounded-enum
> class for things that have a finite number of discrete positions. These
> have log(number of possibilities) information content and can (in
> theory) be serialized with such a number of bits known from the type.
> Designing such a class could be interesting...
In particular, this hypothetical class could be derived more generally
data Blah a b = Baz Int a Bool | Quux | Quuuux b
derived instance (Finite a, Finite b) => Finite (Blah a b)
since Int and Bool are in this class.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the Haskell-prime