transformations-0.2.0.0: Generic representation of tree transformations

Safe HaskellNone
LanguageHaskell98

Generics.MultiRec.Transformations.Main

Synopsis

Documentation

diff :: forall phi top. (Transform phi, Children phi (PF phi) top, EmptyMemo phi top (Ixs phi), ChildrenTable phi top (Ixs phi), GetChildrenTable phi (Ixs phi) top, Eq top) => phi top -> top -> top -> Transformation phi top Source

Find a set of insertions to transform the first into the second tree

apply :: forall phi ix. Transform phi => phi ix -> ix -> Transformation phi ix -> Maybe ix Source

Apply the transformation to the given tree

type family Ixs phi :: [*] Source

type Transformation phi top = [Insert phi top top] Source

Transformations are just sequences of insertions