@hackage prelude-safeenum0.1.1.1

A redefinition of the Prelude's Enum class in order to render it safe.

  • Installation

  • Dependencies (1)

  • Dependents (2)

    @hackage/acme-everything, @hackage/data-fin
  • Package Flags

      base4
       (on by default)

      base-4.0 emits "Prelude deprecated" messages in order to get people to be explicit about which version of base they use.

A redefinition of the Prelude's Enum class in order to render it safe. That is, the Haskell Language Report defines pred, succ, fromEnum, and toEnum to be partial functions when the type is Bounded, but this is unacceptable. We define a new type-class hierarchy for enumeration which is safe and also generalizes to cover types which can only be enumerated in one direction.