generics-mrsop-1.2.2: Generic Programming with Mutually Recursive Sums of Products.

Safe HaskellNone
LanguageHaskell2010

Generics.MRSOP.AG

Contents

Description

Attribute grammars over mutual recursive datatypes

Synopsis

Documentation

zipAnn :: forall phi1 phi2 phi3 ki codes ix. (forall iy. phi1 iy -> phi2 iy -> phi3 iy) -> AnnFix ki codes phi1 ix -> AnnFix ki codes phi2 ix -> AnnFix ki codes phi3 ix #

mapAnn :: (forall iy. chi iy -> phi iy) -> AnnFix ki codes chi ix -> AnnFix ki codes phi ix #

inheritAnn :: forall ki codes chi phi ix. (forall iy. chi iy -> Rep ki (Const ()) (Lkup iy codes) -> phi iy -> Rep ki phi (Lkup iy codes)) -> phi ix -> AnnFix ki codes chi ix -> AnnFix ki codes phi ix #

Inherited attributes

inherit :: forall ki phi codes ix. (forall iy. Rep ki (Const ()) (Lkup iy codes) -> phi iy -> Rep ki phi (Lkup iy codes)) -> phi ix -> Fix ki codes ix -> AnnFix ki codes phi ix #

synthesizeAnn :: forall ki codes chi phi ix. (forall iy. chi iy -> Rep ki phi (Lkup iy codes) -> phi iy) -> AnnFix ki codes chi ix -> AnnFix ki codes phi ix #

Synthesized attributes

synthesize :: forall ki phi codes ix. IsNat ix => (forall iy. IsNat iy => Rep ki phi (Lkup iy codes) -> phi iy) -> Fix ki codes ix -> AnnFix ki codes phi ix #

monoidAlgebra :: Monoid m => Rep ki (Const m) xs -> Const m iy #

sizeAlgebra :: Rep ki (Const (Sum Int)) xs -> Const (Sum Int) iy #

sizeGeneric' :: IsNat ix => Fix ki codes ix -> AnnFix ki codes (Const (Sum Int)) ix #

Annotate each node with the number of subtrees

sizeGeneric :: IsNat ix => Fix ki codes ix -> Const (Sum Int) ix #

Count the number of nodes

Orphan instances

Show k2 => Show1 (Const k2 :: k1 -> Type) # 
Instance details

Methods

show1 :: Const k2 k -> String #

(Show1 f, Show1 g) => Show1 (Product f g :: k -> Type) # 
Instance details

Methods

show1 :: Product f g k0 -> String #