heftia-0.1.0.0: Higher-order version of Freer.
Copyright(c) 2023 Yamada Ryo
LicenseMPL-2.0 (see the file LICENSE)
Maintainerymdfield@outlook.jp
Stabilityexperimental
Portabilityportable
Safe HaskellSafe-Inferred
LanguageGHC2021

Control.Heftia

Description

A type class to abstract away the encoding details of the Heftia carriers.

Synopsis

Documentation

class (forall sig. HFunctor sig => c (h sig)) => Heftia c h | h -> c where Source #

A type class to abstract away the encoding details of the Heftia carrier.

Minimal complete definition

liftSig, interpretHH

Methods

liftSig :: HFunctor sig => sig (h sig) a -> h sig a Source #

Lift a signature into a Heftia carrier.

interpretHH :: (c m, HFunctor sig) => (sig m ~> m) -> h sig a -> m a Source #

translateHH :: (HFunctor sig, HFunctor sig') => (sig (h sig') ~> sig' (h sig')) -> h sig a -> h sig' a Source #

Translate signatures embedded in a Heftia carrier.

reinterpretHH :: HFunctor sig => (sig (h sig) ~> h sig) -> h sig a -> h sig a Source #

retractH :: (Heftia c h, c m) => h (LiftIns m) a -> m a Source #