!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVW X Y Z [ \]^_`abcd e f g h i j k l m n o p q r s t u v w x y z { | } ~               !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRS TUVWXYZ[\]^_`abcd e fghijklmn o pqrstuvwxyz{|}~       !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghij k l m n o p q r s t u v w x!y!z!{!|!}!~!!!""""""""""""""""""""""#######$$$$$$$A%(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None246JK An instance a :< b means that a is a component of b. a can be extracted from b via the method  .      (c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred !"246HJKM ?This data type denotes the composition of two functor families. ~This class represents higher-order functors (Johann, Ghani, POPL '08) which are endofunctors on the category of endofunctors. A higher-order functor f% also maps a natural transformation g :-> h to a natural transformation  f g :-> f h#This type represents co-cones from f to a. f :=> a is isomorphic to f :-> K a-This type represents natural transformations."The parametrised constant functor.The identity Functor.        (c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred !"246HJKM)Higher-order functors that can be folded.Minimal complete definition:   or !.  !"#$%&'  !"#$%&'  !"#$&'% !"#$%&'(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred !"246HJKM)yMap each element of a structure to a monadic action, evaluate these actions from left to right, and collect the results.PAlternative type in terms of natural transformations using functor composition :.:: :hmapM :: Monad m => (a :-> m :.: b) -> t a :-> m :.: (t b)()*()*()*()*(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"<=HJKM+1A (higher-order) term is a context with no holes.,A context might contain holes.-!Phantom type that signals that a / does not contain holes..!Phantom type that signals that a / might contain holes./This data type represents contexts over a signature. Contexts are terms containing zero or more holes. The first type parameter is supposed to be one of the phantom types . and -. The second parameter is the signature of the context. The third parameter is the type family of the holes. The last parameter is the index/label.3This function converts a constant to a term. This assumes that the argument is indeed a constant, i.e. does not have a value for the argument type of the functor f.4;This function unravels the given term at the topmost layer.6CCast a term over a signature to a context over the same signature. +,-./0123456 +,-./0123456 /10.-,+23465 +,-./1023456(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None246JK  (c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None 7 This is the Q%-lifted version of 'abstractNewtypeQ.8This function abstracts away newtype# declaration, it turns them into data declarations.9LThis function provides the name and the arity of the given data constructor.;-Same as normalCon' but expands type synonyms.<9Same as normalConExp' but retains strictness annotations.=LThis function provides the name and the arity of the given data constructor.>7This function returns the name of a bound type variableA]This function provides a list (of the given length) of new names based on the given string.C~Helper function for generating a list of instances for a list of named signatures. For example, in order to derive instances  and ShowF for a signature Exp5, use derive as follows (requires Template Haskell): *$(derive [makeFunctor, makeShowF] [''Exp])DThis function lifts type class instances over sums ofsignatures. To this end it assumes that it contains only methods with types of the form f t1 .. tn -> t where f is the signature that is used to construct sums. Since this function is generic it assumes as its first argument the name of the function that is used to lift methods over sums i.e. a function of type D(f t1 .. tn -> t) -> (g t1 .. tn -> t) -> ((f :+: g) t1 .. tn -> t) where :+: is the sum type constructor. The second argument to this function is expected to be the name of that constructor. The last argument is the name of the class whose instances should be lifted over sums.789:;<=>?@ABCDE789:;<=>?@ABCDE789:;<=>?@ABCDE789:;<=>?@ABCDE&(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneFConstructor printing. H Signature printing. An instance ShowF f gives rise to an instance  Show (Term f). JDerive an instance of HP for a type constructor of any first-order kind taking at least one argument. KDerive an instance of GP for a type constructor of any first-order kind taking at least one argument. FGHIJKFGHIJKFGHIJK'(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneLDerive an instance of P for a type constructor of any first-order kind taking at least one argument. LLL((c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneMDerive an instance of P for a type constructor of any first-order kind taking at least one argument. MMM)(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"N#Signature arbitration. An instance  ArbitraryF f gives rise to an instance Arbitrary (Term f). RDerive an instance of  for a type constructor. SDerive an instance of N for a type constructor of any first-order kind taking at least one argument. It is necessary that all types that are used by the data type definition are themselves instances of . 4This function generates a declaration of the method , for the given list of constructors using .This function generates a declaration of a generator having the given name using the given constructors, i.e., something like this: % <name> :: Gen <type> <name> = ... where <type> is the type of the given constructors. If the constructors do not belong to the same type this function fails. The generated function will generate only elements of this type using the given constructors. All argument types of these constructors are supposed to be instances of .5This function generates a declaration for the method QZ using the given constructors. The constructors are supposed to belong to the same type. NOPQRS NOPQRSNOPQRS*(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneT#Signature normal form. An instance  NFDataF f gives rise to an instance NFData (Term f). VDerive an instance of TP for a type constructor of any first-order kind taking at least one argument. TUVTUVTUV+(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneWDerive an instance of  R for a type constructor of any higher-order kind taking at least two arguments. W WW,(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneXDerive an instance of R for a type constructor of any higher-order kind taking at least two arguments. XXX-(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneYDerive an instance of (R for a type constructor of any higher-order kind taking at least two arguments. Y(YY.(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneZ Signature equality. An instance EqF f gives rise to an instance  Eq (Term f). \Derive an instance of ZP for a type constructor of any first-order kind taking at least one argument. Z[\Z[\Z[\/(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None] Signature ordering. An instance OrdF f gives rise to an instance  Ord (Term f). _Derive an instance of ]P for a type constructor of any first-order kind taking at least one argument. ]^_]^_]^_(c) 2012 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred`AThis type is used for numbering components of a functorial value.clThis function numbers the components of the given functorial value with consecutive integers starting at 0.`abc`abc`abc`abc '(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred!"&(23468=JKM e%Remove annotations from a signature. fMThis class defines how to distribute an annotation over a sum of signatures. g'Inject an annotation over a signature. h(Project an annotation from a signature. iDThis data type adds a constant product (annotation) to a signature. k(Formal product of signatures (functors).nThe :<: constraint is a conjunction of two constraints. The first one is used to construct the evidence that is used to implement the injection and projection functions. The first constraint alone would allow instances such as  F :+: F :<: F or F :+: (F :+: G) :<: F :+: G which have multiple occurrences of the same sub-signature on the left-hand side. Such instances are usually unintended and yield injection functions that are not injective. The second constraint excludes such instances.$Formal sum of signatures (functors).cUtility function to case on a functor sum, without exposing the internal representation of sums. Kdefghijklmnopqrstuvwxyz{|}~<defghijklmnopqrstuvwxyz{|}~K{~}|xzywvutsrqponmklijfghde3defghijklmnopqrstuvwxzy{~}|ijklmn (c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"3=HJKM06This type represents monadic cv-coalgebras over monad m and functor f, and with domain a.0This type represents cv-coalgebras over functor f and with domain a.5This type represents monadic r-coalgebras over monad m and functor f with domain a./This type represents r-coalgebras over functor f and with domain a.3This type represents monadic r-algebras over monad m and functor f and with domain a.-This type represents r-algebras over functor f and with domain a.+This type represents monadic term algebras..This type represents monadic context function.1This type represents monadic signature functions.(This type represents term homomorphisms.&This type represents context function.>This type represents uniform signature function specification.9This type represents a monadic algebra. It is similar to ! but the return type is monadic.!This type represents multisorted f-algebras with a family e of carriers.+Construct a catamorphism for contexts over f with holes of type b, from the given algebra.0Construct a catamorphism from the given algebra.A generalisation of  from terms over f to contexts over f7, where the holes have the type of the algebra carrier.;This function applies a whole context into another context.>This function lifts a many-sorted algebra to a monadic domain.3Construct a monadic catamorphism for contexts over f with holes of type b!, from the given monadic algebra.This is a monadic version of .EThis function applies the given term homomorphism to a term/context.fThis function applies the given term homomorphism to a term/context. This is the top-down variant of .)This function composes two term algebras.6This function composes a term algebra with an algebra.bThis function applies a signature function to the given context. This is the top-down variant of .@This function applies a signature function to the given context./This function composes two signature functions.FLifts the given signature function to the canonical term homomorphism.This function lifts the given signature function to a monadic signature function. Note that term algebras are instances of signature functions. Hence this function also applies to term algebras.SThis function lifts the give monadic signature function to a monadic term algebra.LThis function lifts the given signature function to a monadic term algebra.UThis function applies the given monadic term homomorphism to the given term/context.tThis function applies the given monadic term homomorphism to the given term/context. This is a top-down variant of .QThis function applies the given monadic signature function to the given context.pThis function applies the given monadic signature function to the given context. This is a top-down variant of .1This function composes two monadic term algebras.EThis function composes a monadic term algebra with a monadic algebra FThis function composes a monadic term algebra with a monadic algebra.9This function composes two monadic signature functions. vThis function unfolds the given value to a term using the given unravelling function. This is the unique homomorphism  a -> Term f" from the given coalgebra of type a -> f a to the final coalgebra Term f. This function unfolds the given value to a term using the given monadic unravelling function. This is the unique homomorphism  a -> Term f" from the given coalgebra of type a -> f a to the final coalgebra Term f.@This function constructs a paramorphism from the given r-algebraQThis function constructs a monadic paramorphism from the given monadic r-algebraDThis function constructs an apomorphism from the given r-coalgebra.SThis function constructs a monadic apomorphism from the given monadic r-coalgebra.bThis function constructs the unique futumorphism from the given cv-coalgebra to the term algebra.rThis function constructs the unique monadic futumorphism from the given monadic cv-coalgebra to the term algebra.33330(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneJK Signature printing. An instance ShowHF f gives rise to an instance KShow (HTerm f). Derive an instance of R for a type constructor of any higher-order kind taking at least two arguments.  (c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions) Safe-Inferred!"23468=HJKMMThis class defines how to distribute an annotation over a sum of signatures.5This function injects an annotation over a signature.kThis data type adds a constant product to a signature. Alternatively, this could have also been defined as /data (f :&: a) (g :: * -> *) e = f g e :&: a e.This is too general, however, for example for  productHHom.The subsumption relation.Data type defining coproducts.pUtility function to case on a higher-order functor sum, without exposing the internal representation of sums. 1"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None!"2"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"3HJKMLProject the outermost layer of a term to a sub signature. If the signature g is compound of n atomic signatures, use projectn instead.Tries to coerce a termcontext to a term0context over a sub-signature. If the signature g is compound of n atomic signatures, use  deepProjectn instead.-NInject a term where the outermost layer is a sub signature. If the signature g is compound of n atomic signatures, use injectn instead.7VInject a term over a sub signature to a term over larger signature. If the signature g is compound of n atomic signatures, use  deepInjectn instead.A;This function injects a whole context into another context.B3This function lifts the given functor to a context.C7This function applies the given context with hole type a to a family f) of contexts (possibly terms) indexed by a. That is, each hole h is replaced by the context f h.A      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGF      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGF      !"#$%&'()*+,-./0123456789:;<=>?@DEFGABCA      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFG(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"246HJKMHThis function transforms a function with a domain constructed from a functor to a function with a domain constructed with the same functor but with an additional annotation.IZThis function annotates each sub term of the given term with the given value (of type a).JThis function transforms a function with a domain constructed from a functor to a function with a domain constructed with the same functor but with an additional annotation.KRThis function strips the annotations from a term over a functor with annotations. MThis function is similar to E but applies to signatures with an annotation which is then ignored.HIJKLM HIJKLM HIJKLMHIJKLM(c) Patrick Bahr, 2011BSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"24JKN Signature equality. An instance EqHF f gives rise to an instance  KEq (HTerm f). R4This function implements equality of values of type f a modulo the equality of a; itself. If two functorial values are equal in this sense, eqMod returns a g value containing a list of pairs consisting of corresponding components of the two functorial values. From an EqF functor an : instance of the corresponding term type can be derived.EqF is propagated through sums. NOPQRNOPQRNOPQR NOPQR3(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None24SDerive an instance of NR for a type constructor of any higher-order kind taking at least two arguments. SNOPQSS(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !":HJKMThThis function returns a list of all subterms of the given term. This function is similar to Uniplate's universe function.UoThis function returns a list of all subterms of the given term that are constructed from a particular functor.VThis function transforms every subterm according to the given function in a bottom-up manner. This function is similar to Uniplate's  transform function.WMonadic version of V.[gThis function computes the generic size of the given term, i.e. the its number of subterm occurrences.\;This function computes the generic depth of the given term. TUVWXYZ[\ TUVWXYZ[\ TUVWXYZ[\ TUVWXYZ[\4(c) 2011 Patrick BahrBSD3:Patrick Bahr <paba@diku.dk>, Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None +,-./0123456      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRTUVWXYZ[\"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None246JK]!The desugaring term homomorphism.`Desugar a term.a#Lift desugaring to annotated terms.bDefault desugaring instance.]^_`abc]^_`a]^_c`ab]^_`abc5(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NonedDerive smart constructors for a type constructor of any higher-order kind taking at least two arguments. The smart constructors are similar to the ordinary constructors, but an - is automatically inserted. ddd6"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)NoneeDerive smart constructors with products for a type constructor of any parametric kind taking at least two arguments. The smart constructors are similar to the ordinary constructors, but an  is automatically inserted. eee"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None !"24JKf Signature ordering. An instance OrdHF f gives rise to an instance  Ord (Term f). Ordering of terms. From an f difunctor an ; instance of the corresponding term type can be derived. f is propagated through sums. fghifghihifgfghi(c) 2012 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneJKjAThis type is used for numbering components of a functorial value.mlThis function numbers the components of the given functorial value with consecutive integers starting at 0.jklm(jklmjklm(jklm7"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None24MnDerive an instance of fR for a type constructor of any parametric kind taking at least three arguments. nfgnn (c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneoGiven the name of a type class, where the first parameter is a higher-order functor, lift it to sums of higher-order. Example: class HShowF f where ... is lifted as <instance (HShowF f, HShowF g) => HShowF (f :+: g) where ... .o (CWXYNOPQSdefgnoCNOPQSfgn WX(Ydeoo8(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"234JKM(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"2346=HJKMpIThis multiparameter class defines functors with variables. An instance  HasVar f v denotes that values over f, might contain and bind variables of type v. qIndicates whether the f@ constructor is a variable. The default implementation returns Nothing.r,Indicates the set of variables bound by the fc constructor for each argument of the constructor. For example for a non-recursive let binding:  data Let i e = Let Var (e i) (e i) instance HasVars Let Var where bindsVars (Let v x y) = Map.fromList [(y, (Set.singleton v))] \ If, instead, the let binding is recursive, the methods has to be implemented like this:  bindsVars (Let v x y) = Map.fromList [(x, (Set.singleton v)), (y, (Set.singleton v))] s This indicates that the scope of the bound variable also extends to the right-hand side of the variable binding.1The default implementation returns the empty map.kThis function substitutes variables in a context according to a partial mapping from variables to contexts.Same as q but it returns Nothing instead of Just v if .v@ is contained in the given set of variables.vThis combinator pairs every argument of a given constructor with the set of (newly) bound variables according to the corresponding p type class instance.This combinator combines v with the mfmap function.This combinator combines v with the generic " function. 8Convert variables to holes, except those that are bound.xCThis function checks whether a variable is contained in a context. yEThis function computes the list of variables occurring in a context. ]Algebra for checking whether a variable is contained in a term, except those that are bound.zDThis function computes the set of variables occurring in a context. {DThis function computes the set of variables occurring in a context. })This function composes two substitutions s1 and s2O. That is, applying the resulting substitution is equivalent to first applying s2 and then s1. pqrstuvwxyz{|}pqrstuvwxyz{|}pqrutswxzy{|}vpqrstuvwxyz{|}'(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"24<=HM ~IPolymorphic definition of a term. This formulation is more natural than 9, it leads to impredicative types in some cases, though.$A term is a context with no holes. !Phantom type that signals that a  does not contain holes.!Phantom type that signals that a  might contain holes. This data type represents contexts over a signature. Contexts are terms containing zero or more holes. The first type parameter is supposed to be one of the phantom types  and f. The second parameter is the signature of the context. The third parameter is the type of the holes. This function converts a constant to a term. This assumes that the argument is indeed a constant, i.e. does not have a value for the argument type of the functor f. ,Convert a functorial value into a context. CCast a term over a signature to a context over the same signature. =This function unravels the given term at the topmost layer. ~ ~ ~~'(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"3HJKMK?This type represents a generalised cv-coalgebra over a functor f and carrier a. ;This type represents a monadic cv-coalgebra over a functor f and carrier a. 3This type represents a cv-coalgebra over a functor f and carrier a. 9This type represents a monadic cv-algebra over a functor f and carrier a. 1This type represents a cv-algebra over a functor f and carrier a. :This type represents a monadic r-coalgebra over a functor f and carrier a. 3This type represents an r-coalgebra over a functor f and carrier a. 8This type represents a monadic r-algebra over a functor f and carrier a. 1This type represents an r-algebra over a functor f and carrier a. 8This type represents a monadic coalgebra over a functor f and carrier a. 0This type represents a coalgebra over a functor f and carrier a. CThis type represents a monadic term homomorphism. It is similar to , but has monadic values also in the domain. 3This type represents a monadic term homomorphism. EThis type represents a monadic signature function. It is similar to , but has monadic values also in the domain. 3This type represents a monadic signature function. 0This type represents a monadic context function.*This type represents a term homomorphism. *This type represents a signature function.)This type represents a context function. 9This type represents a monadic algebra. It is similar to " but the return type is monadic. /This type represents an algebra over a functor f and carrier a. +Construct a catamorphism for contexts over f with holes of type a, from the given algebra. 1Construct a catamorphism from the given algebra. A generalisation of  from terms over f to contexts over f:, where the holes have the type of the algebra carrier. <This function applies a whole context into another context. MConvert a monadic algebra into an ordinary algebra with a monadic carrier. 3Construct a monadic catamorphism for contexts over f with holes of type a", from the given monadic algebra. AConstruct a monadic catamorphism from the given monadic algebra. A generalisation of  from terms over f to contexts over fB, where the holes have the type of the monadic algebra carrier. EThis function applies the given term homomorphism to a term/context. XApply a term homomorphism recursively to a term/context. This is a top-down variant of . Compose two term homomorphisms. BCompose an algebra with a term homomorphism to get a new algebra. DCompose a term homomorphism with a coalgebra to get a cv-coalgebra. JCompose a term homomorphism with a cv-coalgebra to get a new cv-coalgebra.AThis function applies a signature function to the given context. `This function applies a signature function to the given context. This is a top-down variant of .0This function composes two signature functions. FThis function composes a signature function with a term homomorphism.EThis function composes a term homomorphism with a signature function.<This function composes an algebra with a signature function.GLifts the given signature function to the canonical term homomorphism.Lift the given signature function to a monadic signature function. Note that term homomorphisms are instances of signature functions. Hence this function also applies to term homomorphisms. ILift the give monadic signature function to a monadic term homomorphism. BLift the given signature function to a monadic term homomorphism. AApply a monadic term homomorphism recursively to a term/context. ]Apply a monadic term homomorphism recursively to a term/context. This a top-down variant of .rThis function constructs the unique monadic homomorphism from the initial term algebra to the given term algebra. IThis function applies a monadic signature function to the given context. hThis function applies a monadic signature function to the given context. This is a top-down variant of .AThis function applies a signature function to the given context. (Compose two monadic term homomorphisms. (Compose two monadic term homomorphisms. (Compose two monadic term homomorphisms. [Compose a monadic algebra with a monadic term homomorphism to get a new monadic algebra. SCompose a monadic algebra with a term homomorphism to get a new monadic algebra. 9This function composes two monadic signature functions. (Compose two monadic term homomorphisms. 9This function composes two monadic signature functions. 9This function composes two monadic signature functions. 3Construct an anamorphism from the given coalgebra. Shortcut fusion variant of .BConstruct a monadic anamorphism from the given monadic coalgebra. 3Construct a paramorphism from the given r-algebra. CConstruct a monadic paramorphism from the given monadic r-algebra. 5Construct an apomorphism from the given r-coalgebra. DConstruct a monadic apomorphism from the given monadic r-coalgebra. This function applies h at the tip of the term.5Construct a histomorphism from the given cv-algebra. EConstruct a monadic histomorphism from the given monadic cv-algebra. 6Construct a futumorphism from the given cv-coalgebra. FConstruct a monadic futumorphism from the given monadic cv-coalgebra. BConstruct a futumorphism from the given generalised cv-coalgebra. EThis function applies a signature function after a term homomorphism.This function applies the given algebra bottom-up while applying the given term homomorphism top-down. Thereby we have no requirements on the source signature f.P  FFP  '(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"&2346HJKM LProject the outermost layer of a term to a sub signature. If the signature g is compound of n atomic signatures, use projectn instead.LProject the outermost layer of a term to a sub signature. If the signature g is compound of n atomic signatures, use projectn instead.Tries to coerce a termcontext to a term0context over a sub-signature. If the signature g is compound of n atomic signatures, use  deepProjectn instead.Tries to coerce a termcontext to a term0context over a sub-signature. If the signature g is compound of n atomic signatures, use  deepProjectn instead.NInject a term where the outermost layer is a sub signature. If the signature g is compound of n atomic signatures, use injectn instead.NInject a term where the outermost layer is a sub signature. If the signature g is compound of n atomic signatures, use injectn instead.VInject a term over a sub signature to a term over larger signature. If the signature g is compound of n atomic signatures, use  deepInjectn instead.VInject a term over a sub signature to a term over larger signature. If the signature g is compound of n atomic signatures, use  deepInjectn instead.<This function injects a whole context into another context. 4This function lifts the given functor to a context. 7This function applies the given context with hole type a to a family f) of contexts (possibly terms) indexed by a. That is, each hole h is replaced by the context f h.    mnnm   (c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"JK4This function implements equality of values of type f a modulo the equality of a; itself. If two functorial values are equal in this sense,  returns a g value containing a list of pairs consisting of corresponding components of the two functorial values. Z is propagated through sums.From an Z functor an : instance of the corresponding term type can be derived.Z[Z[(c) 2010-2012 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"234HJKM:yThis type represents transition functions of generalised deterministic top-down tree acceptors (GDTAs) which have access9This type is needed to construct the product of two DTAs.bThis type represents transition functions of total, deterministic top-down tree acceptors (DTAs).This is a variant of the L type that makes it easier to define DTTs as it avoids the explicit use of ) to inject placeholders into the result.cThis type represents transition functions of total deterministic top-down tree transducers (DTTs).This type represents transition functions of generalised deterministic bottom-up tree acceptors (GUTAs) which have access to an extended state space.cThis type represents transition functions of total, deterministic bottom-up tree acceptors (UTAs).This is a variant of the L type that makes it easier to define UTTs as it avoids the explicit use of ) to inject placeholders into the result.eThis type represents transition functions of total, deterministic bottom-up tree transducers (UTTs).This type represents stateful term homomorphisms. Stateful term homomorphisms have access to a state that is provided (separately) by a bottom-up or top-down state transformation function (or both)."left-biased union of two mappings.-This operator constructs a singleton mapping.This is the empty mapping.HThis function provides access to components of the states from "below".FThis function provides access to components of the state from "above"Turns the explicit parameters ?above and ?below into explicit ones.qThis function turns a stateful homomorphism with a fully polymorphic state type into a (stateless) homomorphism.1This function turns a UTT defined using the type # in to the canonical form of type .DThis function transforms a UTT transition function into an algebra.3This function runs the given UTT on the given term.This function is a variant of 7 that additionally returns the final state of the run.This function generalises V to contexts. Therefore, additionally, a transition function for the holes is needed.:This function composes two UTTs. (see TATA, Theorem 6.4.5)-This function composes a UTT with an algebra.@This combinator composes a UTT followed by a signature function.@This combinator composes a signature function followed by a UTT.:This combinator composes a UTT followed by a homomorphism.:This combinator composes a homomorphism followed by a UTT.?Changes the state space of the UTA using the given isomorphism.SThis combinator runs the given UTA on a term returning the final state of the run.=This function combines the product UTA of the two given UTAs.sThis function constructs a UTT from a given stateful term homomorphism with the state propagated by the given UTA.sThis function applies a given stateful term homomorphism with a state space propagated by the given UTA to a term.This is a variant of / that also returns the final state of the run.3This combinator turns an arbitrary UTA into a GUTA.PThis combinator turns a GUTA with the smallest possible state space into a UTA.&This combinator runs a GUTA on a term.3This combinator constructs the product of two GUTA.1This function turns a DTT defined using the type # in to the canonical form of type .4Thsis function runs the given DTT on the given tree.3This function runs the given DTT on the given tree.`This function composes two DTTs. (see W.C. Rounds /Mappings and grammars on trees/, Theorem 2.)8This function composes a signature function after a DTT..This function composes a DTT after a function.2This function composes a homomorphism after a DTT. 2This function composes a DTT after a homomorphism. ?Changes the state space of the DTA using the given isomorphism. ?This function constructs the product DTA of the given two DTAs.VThis function constructs the pointwise product of two maps each with a default value.Apply the given state mapping to the given functorial value by adding the state to the corresponding index if it is in the map and otherwise adding the provided default state. uThis function constructs a DTT from a given stateful term-- homomorphism with the state propagated by the given DTA. sThis function applies a given stateful term homomorphism with a state space propagated by the given DTA to a term.3This combinator turns an arbitrary DTA into a GDTA.PThis combinator turns a GDTA with the smallest possible state space into a DTA.XThis combinator constructs the product of two dependant top-down state transformations.This is a synonym for .This combinator combines a bottom-up and a top-down state transformations. Both state transformations can depend mutually recursive on each other.This combinator runs a stateful term homomorphisms with a state space produced both on a bottom-up and a top-down state transformation.>     5      3     ;     (c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"&3JKMbThis function returns the subterm of a given term at the position specified by the given path or Nothing' if the input term has no such subtermThis function returns the subterm of a given term at the position specified by the given path. This function is a variant of ; which fails if there is no subterm at the given position.hThis function returns a list of all subterms of the given term. This function is similar to Uniplate's universe function.oThis function returns a list of all subterms of the given term that are constructed from a particular functor.This function transforms every subterm according to the given function in a bottom-up manner. This function is similar to Uniplate's  transform function.Monadic version of .gThis function computes the generic size of the given term, i.e. the its number of subterm occurrences.<This function computes the generic height of the given term.    (c) 2013 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"HJKM*This type is a more convenient variant of  ! with which one can avoid using 7 explicitly when injecting placeholders in the result. This type represents MTTs with regular look-ahead, i.e. MTTs that have access to information that is generated by a separate UTA.!This type is a variant of the "I which is more convenient to work with as it avoids the explicit use of ( to embed placeholders into the result."%This type is an instantiation of the & type to a state space with only a single state with a single accumulation parameter (i.e. the state space is the identity functor).#zThis type constructor is used to define the state space of an MTT that is obtained by composing an MTT followed by a DTT.%This is a variant of the type &G that makes it easier to define MTTs as it avoids the explicit use of ( when using placeholders in the result.&HThis type represents total deterministic macro tree transducers (MTTs).'CThis function turns an MTT defined using the more convenient type %! into its canonical form of type &.(kThis function defines the semantics of MTTs. It applies a given MTT to an input with and an initial state.)This function composes a DTT followed by an MTT. The resulting MTT's semantics is equivalent to the function composition of the semantics of the original MTT and DTT.This function is a variant of @ that is used to define composition, similarly to the function .*This function composes an MTT followed by a DTT. The resulting MTT's semantics is equivalent to first running the original MTT and then the DTT.+hThis function transforms an MTT of type |MacroTransId| into the canonical type such that it can be run.,iThis function transforms an MTT of type |MacroTransId'| into the canonical type such that it can be run.-This function turns an MTT with regular look-ahead defined using the more convenient type |MacroTransLA'| into its canonical form of type |MacroTransLA|..This function defines the semantics of MTTs with regular look-ahead. It applies a given MTT with regular look-ahead (including an accompanying bottom-up state transition function) to an input with and an initial state./IThis function composes an MTT with regular look-ahead followed by a DTT. !"#$%&'()*+,-./ !"#$%&'()*+,-./&%'()*"!+, -./#$ !"#$%&'()*+,-./(c) 2010-2013 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"&2346HJKM 0Transform a function with a domain constructed from a functor to a function with a domain constructed with the same functor, but with an additional annotation. 1Transform a function with a domain constructed from a functor to a function with a domain constructed with the same functor, but with an additional annotation. 2CStrip the annotations from a term over a functor with annotations. 3)Lift a term homomorphism over signatures f and gR to a term homomorphism over the same signatures, but extended with annotations. 42Lift a stateful term homomorphism over signatures f and g[ to a stateful term homomorphism over the same signatures, but extended with annotations.51Lift a bottom-up tree transducer over signatures f and gZ to a bottom-up tree transducer over the same signatures, but extended with annotations.60Lift a top-down tree transducer over signatures f and gY to a top-down tree transducer over the same signatures, but extended with annotations.7-Lift a macro tree transducer over signatures f and gV to a macro tree transducer over the same signatures, but extended with annotations.8FLift a macro tree transducer with regular look-ahead over signatures f and gm to a macro tree transducer with regular look-ahead over the same signatures, but extended with annotations.91Lift a monadic term homomorphism over signatures f and g[ to a monadic term homomorphism over the same signatures, but extended with annotations. :4Annotate each node of a term with a constant value. ;This function adds unique annotations to a term/context. Each node in the term/context is annotated with its path from the root, which is represented as an integer list. It is implemented as a DTT.<This function is similar to E but applies to signatures with an annotation which is then ignored. 0123456789:;<defghijkl0123456789:;<ijklfghde0123456789:;< 0123456789:;<9(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None=Derive smart constructors for a type constructor of any first-order kind taking at least one argument. The smart constructors are similar to the ordinary constructors, but an  is automatically inserted. ===:"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None>Derive smart constructors with products for a type constructor of any parametric kind taking at least one argument. The smart constructors are similar to the ordinary constructors, but an g is automatically inserted. >>>(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None&3HJKM =This type represents position representations for a functor fN. It is a function that extracts a number of components (of polymorphic type a3) from a functorial value and puts it into a list.?GThis type represents algebras which have terms with thunks as carrier.@*This type represents contexts with thunks.A'This type represents terms with thunks.B7This function turns a monadic computation into a thunk.C Variant of  for the typex @ and A.DDThis function evaluates all thunks until a non-thunk node is found.F?This function first evaluates the argument term into whnf via D and then projects the top-level signature to the desired subsignature. Failure to do the projection is signalled as a failure in the monad.G:This function inspects the topmost non-thunk node (using D") according to the given function.H Variant of G with flipped argument positionsIHThis function inspects the topmost non-thunk nodes of two terms (using D") according to the given function.J#This function evaluates all thunks.KThis function evaluates all thunks while simultaneously projecting the term to a smaller signature. Failure to do the projection is signalled as a failure in the monad as in F.L%This function inspects a term (using J#) according to the given function.M Variant of L with flipped argument positionsN(This function inspects two terms (using J#) according to the given function.OAThis combinator runs a monadic catamorphism on a term with thunksP:This combinator runs a catamorphism on a term with thunks.Q}This combinator makes the evaluation of the given functor application strict by evaluating all thunks of immediate subterms.R This combinator is a variant of Q that only makes a subset of the arguments of a functor application strict. The first argument of this combinator specifies which positions are supposed to be strict.S4This function decides equality of terms with thunks. ?@ABCDEFGHIJKLMNOPQRS?@ABCDEFGHIJKLMNOPQRSA@BCDEFJKGILNHM?POSQR ?@ABCDEFGHIJKLMNOPQRSHM;(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None&3JKVDerive an instance of !P for a type constructor of any first-order kind taking at least one argument. !"#$TU%VTUV!"#$TU%V(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)NoneWDerive an instance of P for a type constructor of any first-order kind taking at least one argument. XDerive an instance of  for a type constructor. YpGiven the name of a type class, where the first parameter is a functor, lift it to sums of functors. Example: class ShowF f where ... is lifted as 9instance (ShowF f, ShowF g) => ShowF (f :+: g) where ... . WXY(CFGHIJKLMNOPQRSTUVZ[\]^_=>TUVWXY(CHIJFGKZ[\]^_WLMVTUNOPQSRXTUV=>YWXY<(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"JK&] is propagated through sums.'From an ] functor an : instance of the corresponding term type can be derived.&(')]^]^&(')=(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None !"234JK*+,-TUTU*+,->(c) 2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"24JK. Instances of N! are closed under forming sums. /This lifts instances of N to instances of & for the corresponding context type. 0This lifts instances of N to instances of N* for the corresponding context functor.1This lifts instances of N to instances of " for the corresponding term type. ./0213NOPQNOPQ./0213?'(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"2JK456789:HIHI456789:(c) 2010-2011 Patrick BahrBSD3=Patrick Bahr <paba@diku.dk> and Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None !"246JKZIThis multiparameter class defines functors with variables. An instance  HasVar f v denotes that values over f, might contain and bind variables of type v. [Indicates whether the f@ constructor is a variable. The default implementation returns Nothing.\,Indicates the set of variables bound by the fc constructor for each argument of the constructor. For example for a non-recursive let binding: } data Let e = Let Var e e instance HasVars Let Var where bindsVars (Let v x y) = Map.fromList [(y, (Set.singleton v))] \ If, instead, the let binding is recursive, the methods has to be implemented like this:  bindsVars (Let v x y) = Map.fromList [(x, (Set.singleton v)), (y, (Set.singleton v))] s This indicates that the scope of the bound variable also extends to the right-hand side of the variable binding.1The default implementation returns the empty map.][This type represents substitutions of terms, i.e. finite mappings from variables to terms.^aThis type represents substitutions of contexts, i.e. finite mappings from variables to contexts.;AThis multiparameter class defines substitution of values of type t for variables of type v in values of type a. <Same as [ but it returns Nothing instead of Just v if .v@ is contained in the given set of variables.`This combinator pairs every argument of a given constructor with the set of (newly) bound variables according to the corresponding Z type class instance.=This combinator combines ` with the generic > function.?This combinator combines ` with the generic @ function. a8Convert variables to holes, except those that are bound.A]Algebra for checking whether a variable is contained in a term, except those that are bound.bCThis function checks whether a variable is contained in a context. B\Algebra for generating a set of variables contained in a term, except those that are bound.cEThis function computes the list of variables occurring in a context. dDThis function computes the set of variables occurring in a context. eEThis function computes the set of variables occurring in a constant. fApply the given substitution.g)This function composes two substitutions s1 and s2O. That is, applying the resulting substitution is equivalent to first applying s2 and then s1. Z[\]^;_<`=?aAbBcdefgCDEZ[\]^_`abcdefgZ[\]^abdce_fg`Z[\]^;_<`=?aAbBcdefgCDE(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"3F/This is an auxiliary function for implementing h. It behaves similarly as match but is oblivious to non-linearity. Therefore, the substitution that is returned maps holes to non-empty lists of terms (resp. contexts in general). This substitution is only a matching substitution if all elements in each list of the substitution's range are equal. hThis function takes a context c> as the first argument and tries to match it against the term t( (or in general a context with holes in a). The context c matches the term t if there is a matching substitution s\ that maps holes to terms (resp. contexts in general) such that if the holes in the context c, are replaced according to the substitution s , the term t$ is obtained. Note that the context c might be non-linear, i.e. has multiple holes that are equal. According to the above definition this means that holes with equal holes have to be instantiated by equal terms! iThis function is similar to hO but instead of a context it matches a term with variables against a context. FhiZ[\]^_`abcdefghihiFhi (c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None!"HMjThis type represents a potential single step reduction from any input. If there is no single step then the return value is the input together with False6. Otherwise, the successor is returned together with True.kGThis type represents a potential single step reduction from any input.lBThis type represents term rewriting systems (TRSs) from signature f to signature g over variables of type v. m7This type represents term rewrite rules from signature f to signature g over variables of type v nThis type represents variables.oThis type represents recursive program schemes. pThis function tries to match the given rule against the given term (resp. context in general) at the root. If successful, the function returns the right hand side of the rule and the matching substitution. qThis function tries to match the rules of the given TRS against the given term (resp. context in general) at the root. The first rule in the TRS that matches is then used and the corresponding right-hand side as well the matching substitution is returned.rThis function tries to apply the given rule at the root of the given term (resp. context in general). If successful, the function returns the result term of the rewrite step; otherwise Nothing. sThis function tries to apply one of the rules in the given TRS at the root of the given term (resp. context in general) by trying each rule one by one using r8 until one rule is applicable. If no rule is applicable Nothing is returned. t2This is an auxiliary function that turns function f of type (t -> Maybe t) into functions f' of type  t -> (t,Bool). f' x evaluates to (y,True) if f x evaluates to Just y , and to  (x,False) if f x evaluates to NothingW. This function is useful to change the output of functions that apply rules such as s. uThis function performs a parallel reduction step by trying to apply rules of the given system to all outermost redexes. If the given term contains no redexes, Nothing is returned. vThis function performs a parallel reduction step by trying to apply rules of the given system to all outermost redexes and then recursively in the variable positions of the redexes. If the given term does not contain any redexes, Nothing is returned. wZThis function applies the given reduction step repeatedly until a normal form is reached. jklmnopqrstuvwjklmnopqrstuvwonmlkjpqrstuvwjklmnopqrstuvw!(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None246x@This class specifies the decomposability of a functorial value. y-This function decomposes a functorial value. z/This type represents decompositions of terms. {:This type represents decompositions of functorial values. ~<This function computes the structure of a functorial value. =This function computes the arguments of a functorial value. !This function decomposes a term. xyz{|}~G xyz{|}~ {}|zxy~xyz{}|~G"(c) 2010-2011 Patrick BahrBSD3Patrick Bahr <paba@diku.dk> experimentalnon-portable (GHC Extensions)None3 MThis is the unification monad that is used to run the unification algorithm.=This type represents the state for the unification algorithm.FThis type represents errors that might occur during the unification. (This type represents list of equations. HThis type represents equations between terms over a specific signature. JThis is used in order to signal a failed occurs check during unification.KThis is used in order to signal a head symbol mismatch during unification.JThis function applies a substitution to each term in a list of equations.uThis function returns the most general unifier of the given equations using the algorithm of Martelli and Montanari. QThis function runs a unification monad with the given initial list of equations.@"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None!"HIJHIJHIJA'(c) 2010-2011 Patrick Bahr, Tom HvitvedBSD3:Patrick Bahr <paba@diku.dk>, Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)NoneZ[]^defghijklmn~0123456789:;<#None2The ` algebra of a functor. The default instance creates a tree with the same structure as the term.Convert a term to a KShow a term using ASCII artPrint a term using ASCII art0Write a term to an HTML file with foldable nodes$"(c) 2011 Patrick Bahr, Tom HvitvedBSD3Tom Hvitved <hvitved@diku.dk> experimentalnon-portable (GHC Extensions)None &246JK!The desugaring term homomorphism.Desugar a term.#Lift desugaring to annotated terms.Default desugaring instance.LBCDBEFBGHIJKIJLIJMNOPNOQ%R%STUVWXYZ[[\]]^__`aabcdefghijklmnopqrstutqvwxyz{|}~&&&&&&'())))))***+,-...///                                                                                                ! "0#0$0%0&0'0(           ) * + , - . / 0 1 2 3 456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~3567 qrstutqvwyzx      !">H[eruopq    vxyz  w{9: !"#$%&';(;);*+,-./ 0 1 2 3 4 5 6 7 8 9 : ; < =!>!?!@!A!B!4!C!D!E"F"G"G"H"I"J"J"K"L"M"N"O"P"Q"R"S"T"U"V"W"X"Y#Z#[#\#]#^#_#`$$$$$$$%a%b%c%d%e%f%g%h%i%j%klmnopqrstuv&w&x'y'z(y(z){)|)}+y,y,z,~-y-z/0111222B78888888-    ;;;;;<<<<====>>>>>>???????BCBE!@@@compdata-0.8.0.1Data.Comp.DeriveData.Comp.NumberData.Comp.Automata.ProductData.Comp.Multi.HFunctorData.Comp.Multi.HFoldableData.Comp.Multi.HTraversableData.Comp.Multi.TermData.Comp.Derive.UtilsData.Comp.Multi.DeriveData.Comp.Equality Data.Comp.OpsData.Comp.Multi.AlgebraData.Comp.Multi.OpsData.Comp.Multi.SumData.Comp.Multi.AnnotationData.Comp.Multi.EqualityData.Comp.Multi.GenericData.Comp.Multi.DesugarData.Comp.Multi.OrderingData.Comp.Multi.NumberData.Comp.Multi.VariablesData.Comp.TermData.Comp.Algebra Data.Comp.SumData.Comp.AutomataData.Comp.GenericData.Comp.MacroAutomataData.Comp.AnnotationData.Comp.ThunkData.Comp.VariablesData.Comp.MatchingData.Comp.TermRewritingData.Comp.DecomposeData.Comp.UnificationData.Comp.RenderData.Comp.Desugar!Data.Comp.Automata.Product.DeriveData.Comp.Derive.ShowData.Comp.Derive.FoldableData.Comp.Derive.TraversableData.Comp.Derive.ArbitraryData.Comp.Derive.DeepSeqData.Comp.Multi.Derive.HFunctor Data.Comp.Multi.Derive.HFoldable#Data.Comp.Multi.Derive.HTraversableData.Comp.Derive.EqualityData.Comp.Derive.OrderingData.Comp.Multi.Derive.Show"Data.Comp.Multi.Derive.Projections!Data.Comp.Multi.Derive.InjectionsData.Comp.Multi.Derive.EqualityData.Comp.Multi(Data.Comp.Multi.Derive.SmartConstructors)Data.Comp.Multi.Derive.SmartAConstructorsData.Comp.Multi.Derive.OrderingData.Comp.Multi.Show"Data.Comp.Derive.SmartConstructors#Data.Comp.Derive.SmartAConstructorsData.Comp.Derive.HaskellStrictData.Comp.OrderingData.Comp.DeepSeqData.Comp.ArbitraryData.Comp.ShowData.Comp.Derive.Projections Data.CompbaseGHC.BaseFunctor Data.FoldableFoldableData.Traversable TraversableQuickCheck-2.7.6Test.QuickCheck.Arbitraryshrink arbitrary Arbitrarydeepseq-1.3.0.2Control.DeepSeqrnfNFData:<pr:.:CompHFunctorhfmapNatM:=>:->AunAEunEKunKIunIrunE HFoldablehfoldhfoldMaphfoldrhfoldlhfoldr1hfoldl1htoListkfoldrkfoldl HTraversablehmapM htraverseTermContextNoHoleHoleCxtConst constTermunTermsimpCxttoCxtabstractNewtypeQabstractNewtype normalCon normalCon' normalConExpnormalConStrExpabstractConType tyVarBndrName containsType containsType'newNames tupleTypesderive liftSumGenfindSig ShowConstr showConstrShowFshowF makeShowFmakeShowConstr makeFoldablemakeTraversable ArbitraryF arbitraryF' arbitraryFshrinkF makeArbitrarymakeArbitraryFNFDataFrnfF makeNFDataF makeHFunctor makeHFoldablemakeHTraversableEqFeqFmakeEqFOrdFcompareFmakeOrdFNumbered unNumberednumberRemAremADistAnninjectAprojectA:&::*::=::<:NoDup Duplicates Duplicates'InOrResSumResRightResLeftDestrPosResSingPosCompPosSimpPos SimpRightSimpLeftSimpHereGetEmbDgetEmbDEmbDSumDGoRightDGoLeftDHereDPick2SplitPickGetEmbEmbFound AmbiguousNotFoundPosSumGoRightGoLeftHere:+:InrInlfromInlfromInrcaseFinj_injproj_projsplffstfsnd$fDistAnn:+:p:+:$fDistAnnfp:&: $fRemA:&:f $fRemA:+::+:$fTraversable:&: $fFoldable:&: $fFunctor:&:$fNoDupFalsefg$fGetEmbDFound:+:g$fGetEmbDFoundf:+:$fGetEmbDFoundf:+:0$fGetEmbDFoundff$fTraversable:+: $fFoldable:+: $fFunctor:+:CVCoalgMCVCoalgRCoalgMRCoalgRAlgMRAlgCoalgMCoalgHomMCxtFunMSigFunMHomCxtFunSigFunAlgMAlgfreecatacata'appCxtliftMAlgfreeMcataMcataM'appHomappHom'compHomcompAlg appSigFun' appSigFun compSigFunhomsigFunMhom'homMappHomMappHomM' appSigFunM appSigFunM'compHomMcompAlgM compAlgM' compSigFunManaanaMparaparaMapoapoMfutufutuMKShowkshowShowHFshowHFshowHF' makeShowHFcaseHfstsnd$fHTraversable:&:$fHFoldable:&: $fHFunctor:&: $f:<:f:+: $f:<:f:+:0$f:<:ff$fHTraversable:+:$fHFoldable:+: $fHFunctor:+:proj2proj3proj4proj5proj6proj7proj8proj9proj10projectproject2project3project4project5project6project7project8project9 project10 deepProject deepProject2 deepProject3 deepProject4 deepProject5 deepProject6 deepProject7 deepProject8 deepProject9 deepProject10inj2inj3inj4inj5inj6inj7inj8inj9inj10injectinject2inject3inject4inject5inject6inject7inject8inject9inject10 deepInject deepInject2 deepInject3 deepInject4 deepInject5 deepInject6 deepInject7 deepInject8 deepInject9 deepInject10 injectCxtliftCxt substHoles injectConst injectConst2 injectConst3 projectConstliftAannliftA'stripApropAnnproject'EqHFeqHFKEqkeqheqModmakeEqHFsubterms subterms' transform transformMquerysubssubs'sizedepthDesugardesugHom desugHom'desugardesugarA $fDesugarfg $fDesugar:+:hsmartConstructorssmartAConstructorsOrdHF compareHFKOrdkcompare makeOrdHFliftSumHasVarsisVar bindsVarsSubstCxtSubstGSubst getBoundVars varsToHoles containsVar variableList variables variables'appSubst compSubstPTermCVCoalg'CVAlgMCVAlgHomMDSigFunMDalgM compCoalg compCVCoalg compSigFunHom compHomSigFun compAlgSigFunhomMD appSigFunMDcompSigFunHomMcompHomSigFunMcompAlgSigFunMana'histohistoMfutu'project_ deepProject_inject_ deepInject_split substHoles'eqMod DDownState DownState DownTrans' DownTransDUpStateUpStateUpTrans'UpTransQHom&|->obelowabovepureHom mkUpTrans runUpTrans compUpTranscompAlgUpTranscompSigUpTranscompUpTransSigcompHomUpTranscompUpTransHom tagUpState runUpState prodUpStateupTransrunUpHom runUpHomStdUpStateupState runDUpState prodDUpState|*| mkDownTrans runDownTrans compDownTranscompSigDownTranscompDownTransSigcompHomDownTranscompDownTransHom tagDownState prodDownState downTrans runDownHom dDownState downStateprodDDownState>*< runDStaterunQHom getSubterm getSubterm' transform'gsizeheight MacroTransLA' MacroTransLA MacroTransId' MacroTransId:^: MacroTrans' MacroTrans mkMacroTrans runMacroTrans compMacroDown compDownMacrofromMacroTransIdfromMacroTransId'mkMacroTransLArunMacroTransLAcompDownMacroLApropAnnQ propAnnUp propAnnDown propAnnMacropropAnnMacroLApropAnnMpathAnnAlgTCxtTTermTthunkinjectTwhnfwhnf'whnfPreval#>eval2nfnfPrdeepEval#>> deepEval2cataTMcataTstrictstrictAteqT haskellStricthaskellStrict'makeHaskellStrict makeFunctor makeNFData substVarsmatchCxt matchTermBStepStepTRSRuleVarRPS matchRule matchRulesappRuleappTRSbStep parTopStep parallelStepreduce Decomposedecomp DecompTermDecompFun structure arguments decomposeUnifyM UnifyStateusEqsusSubst UnifErrorHeadSymbolMismatchFailedOccursCheck EquationsEquationfailedOccursCheckheadSymbolMismatch appSubstEqunify runUnifyM withNextEqputEqs putBindingrunUnify unifyStep$fErrorUnifErrorRender stringTreeAlg stringTreeshowTermdrawTerm writeHtmlTerm $fRender:+:DirRL genAllInstsgenDirsgenInstgenTypegenPatgenEx genPatExppairT$fOrdK$fEqK $fFunctorK $fFunctorI$fHTraversableCxt$fHFoldableCxt $fHFunctorCxt $f:<(,)(,)$f: