finitary

A better, more type-safe Enum.

https://notabug.org/sheaf/finitary

Latest on Hackage:2.1.1.1

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

GPL-3.0-or-later licensed by Koz Ross
Maintained by Sam Derbyshire

Provides a type class witnessing that a type has finitely-many inhabitants, as well as its cardinality. Also provides an auto-deriving framework using GHC Generics, together with a range of instances for existing types.