HORIZON HASKELLDocslts/ghc-10.0.xc62e4de2026-10-19Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · c62e4de · 2026-10-19

Modulederiving-compat-0.6.8Haskell2010

Data.Enum.Deriving.Internal

Exports functions to mechanically derive Enum instances.

Note: this is an internal module, and as such, the API presented here is not guaranteed to be stable, even between minor releases of this library.

  • 7 values

Enum

7 declarations
valuederiveEnum :: Name -> Q [Dec]
#

Generates an Enum instance declaration for the given data type or data family instance.

valuemakeSucc :: Name -> Q Exp
#

Generates a lambda expression which behaves like succ (without requiring an Enum instance).

valuemakePred :: Name -> Q Exp
#

Generates a lambda expression which behaves like pred (without requiring an Enum instance).