prelude-safeenum

A redefinition of the Prelude's Enum class in order to render it safe. http://code.haskell.org/~wren/

LTS Haskell 14.2:0.1.1.2
Stackage Nightly 2019-08-25:0.1.1.2
Latest on Hackage:0.1.1.2

See all snapshots prelude-safeenum appears in

BSD-3-Clause licensed by wren gayle romano

Module documentation for 0.1.1.2

This version can be pinned in stack with:prelude-safeenum-0.1.1.2@sha256:4b15ef19a18c81de292677f8837a92463e9fe335d3f61db394c6cdf782a89762,2158

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.

Depends on 1 package(full list with versions):
comments powered byDisqus