h*B=:      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                                                                                        0.3  Safe-Inferred1 deep-transformationsTransformation under a deep-transformationsTransformation under a deep-transformationsTransformation under a deep-transformations"Composition of two transformations deep-transformationsBefore we can apply a  , we also need to declare   which base types it is applicable and how it works. If the transformation is natural, we'll need only one instance declaration.:{0instance MaybeToList `Transformation.At` a where MaybeToList $ Just x = [x] MaybeToList $ Nothing = []:}(MaybeToList Transformation.$ (Just True)[True] An unnatural   can behave differently depending on the base type and even on its value.:{5instance {-# OVERLAPS #-} MaybeToList `At` Char where MaybeToList $ Just '\0' = [] MaybeToList $ Just c = [c] MaybeToList $ Nothing = []:} deep-transformationsApply the transformation t at type x to map   to the  functor. deep-transformationsA  , natural or not, maps one functor to another. For example, here's the declaration for a transformation that maps  to `[]`::{data MaybeToList = MaybeToList)instance Transformation MaybeToList where" type Domain MaybeToList = Maybe! type Codomain MaybeToList = []:}deep-transformationsAlphabetical synonym for        0 Safe-Inferred6 deep-transformationsDrop-in implementation of  deep-transformationsDrop-in implementation of  7 that preserves all attributes with every original node deep-transformations7The core function to tie the recursive knot, turning a - for a node into its ..!deep-transformations/Another way to tie the recursive knot, using a - to add " information to every node"deep-transformations(All inherited and synthesized attributes&deep-transformationsThe core type class for defining the attribute grammar. The instances of this class typically have a form like instance Attribution MyAttGrammar MyNode (Semantics MyAttGrammar) Identity where attribution MyAttGrammar{} (Identity MyNode{}) (Inherited fromParent, Synthesized MyNode{firstChild= fromFirstChild, ...}) = (Synthesized _forMyself, Inherited MyNode{firstChild= _forFirstChild, ...})If you prefer to separate the calculation of different attributes, you can split the above instance into two instances of the   and  ! classes instead. If you derive  instances for your attributes, you can even define each synthesized attribute individually with a   instance.'deep-transformations9The attribution rule for a given transformation and node.(deep-transformationsType family that maps a node type to the type of its attributes, indexed per type constructor.)deep-transformationsType constructor wrapping the inherited attributes for the given transformation.,deep-transformations A node's , is a natural tranformation from the node's inherited attributes to all its attributes paired with the preserved node.-deep-transformationsAn attribution rule maps a node's inherited attributes and its child nodes' synthesized attributes to the node's synthesized attributes and the children nodes' inherited attributes..deep-transformations A node's . is a natural tranformation from the node's inherited attributes to its synthesized attributes./deep-transformationsType constructor wrapping the synthesized attributes for the given transformation. !"%$#&'()+*,-./10()+*/10.,"%$#- !&' Safe-Inferred G :deep-transformationsLike Transformation.Deep.8 except it traverses an additional wrapper around the entire tree<deep-transformationsLike Transformation.Deep.4' except the entire tree is also wrapped>deep-transformationsLike Transformation.Deep.6< except it maps an additional wrapper around the entire tree@deep-transformationsAlphabetical synonym for ?Adeep-transformationsDefault implementation for ?( that maps the wrapper and then the treeBdeep-transformationsDefault implementation for ?( that maps the tree and then the wrapperCdeep-transformationsDefault implementation for =) that folds the wrapper and then the treeDdeep-transformationsDefault implementation for =) that folds the tree and then the wrapperEdeep-transformationsDefault implementation for ;- that traverses the wrapper and then the treeFdeep-transformationsDefault implementation for ;- that traverses the tree and then the wrapper :;<=>?@ABCDEF >?<=:;@ABCDEF?4 Safe-Inferred67 4deep-transformationsLike Transformation.Shallow.  except it folds all descendants and not only immediate children6deep-transformationsLike Transformation.Shallow. ? except it maps all descendants and not only immediate children8deep-transformationsLike Transformation.Shallow.  except it folds all descendants and not only immediate childrenGdeep-transformationsLike 4 for data types with two type constructor parametersJdeep-transformationsLike 4 for data types with two type constructor parametersNdeep-transformationsCompose a regular type constructor with a data type with two type constructor parametersQdeep-transformationsA tuple of only one elementTdeep-transformationsAlphabetical synonym for 7Udeep-transformationsEquivalent of 456789GIHJMLKNPOQSRTU674589QSRNPOJMLKGIHTU74 Safe-Inferred^ Safe-Inferred7$ deep-transformationsDrop-in implementation of  deep-transformationsDrop-in implementation of  4 that stores all attributes with every original nodedeep-transformationsDrop-in implementation of ?deep-transformations7The core function to tie the recursive knot, turning a  for a node into its .deep-transformations/Another way to tie the recursive knot, using a > to add attributes to every node througha stateful calculationdeep-transformationsDrop-in implementation of ;4 that stores all attributes with every original nodedeep-transformationsThe core type class for defining the attribute grammar. The instances of this class typically have a form like instance Attribution MyAttGrammar MyMonoid MyNode (Semantics MyAttGrammar) Identity where attribution MyAttGrammar{} (Identity MyNode{}) Atts{inh= fromParent, syn= fromChildren} = Atts{syn= toParent, inh= toChildren}deep-transformations9The attribution rule for a given transformation and node.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules and preservation of the attribute with the original nodes.deep-transformations A node's ; maps its inherited attribute to its synthesized attribute.deep-transformationsAn attribution rule maps a node's inherited attribute and its child nodes' synthesized attribute to the node's synthesized attribute and the children nodes' inherited attributes.deep-transformations A node's ; maps its inherited attribute to its synthesized attribute. Safe-Inferred* deep-transformationsDrop-in implementation of  deep-transformationsDrop-in implementation of  4 that stores all attributes with every original nodedeep-transformationsDrop-in implementation of ?deep-transformationsThe core type class for defining the attribute grammar. The instances of this class typically have a form like instance Attribution MyAttGrammar MyMonoid MyNode (Semantics MyAttGrammar) Identity where attribution MyAttGrammar{} (Identity MyNode{}) Atts{inh= fromParent, syn= fromChildren} = Atts{syn= toParent, inh= toChildren}deep-transformations9The attribution rule for a given transformation and node.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules and preservation of the attribute with the original nodes.deep-transformations A node's ; maps its inherited attribute to its synthesized attribute.deep-transformationsAn attribution rule maps a node's inherited attribute and its child nodes' synthesized attribute to the node's synthesized attribute and the children nodes' inherited attributes.deep-transformations A node's ; maps its inherited attribute to its synthesized attribute. Safe-Inferred+Q  Safe-Inferred ,deep-transformationsTransform (naturally) the containing functor of every node in the given tree.deep-transformationsPass down the given record of inherited fields to child nodes.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules.deep-transformationsA half of the &0 class used to specify all inherited attributes.deep-transformationsWrapper for a field that should be automatically synthesized by folding together all child nodes' synthesized attributes of the same name.deep-transformationsTransformation wrapper that allows automatic inference of attribute rules and preservation of all attributes with the original nodes.deep-transformationsWrapper for a field that should be automatically synthesized by replacing every child node by its synthesized attribute of the same name.deep-transformations0Extract the value from the transformation domaindeep-transformations-Class for specifying a single named attributedeep-transformationsA half of the &2 class used to specify all synthesized attributes.deep-transformationsWrapper for a field that should be automatically synthesized by traversing over all child nodes and applying each node's synthesized attribute of the same name.deep-transformationsUsed for accumulating the  fields deep-transformations-Internal transformation for accumulating the  attributes.deep-transformationsInternal transformation for passing down the inherited attributes.deep-transformations,Internal transformation for replicating the  attributes.deep-transformations+Internal transformation for traversing the  attributes.deep-transformationsThe  mirror of deep-transformationsThe  mirror of deep-transformations The default  method definition for  fields.deep-transformationstransformation deep-transformations tree nodedeep-transformationsinherited attributes deep-transformationssynthesized attributesdeep-transformationsattribute namedeep-transformationstransformationdeep-transformations tree nodedeep-transformationsinherited attributesdeep-transformationssynthesized attributesdeep-transformationstransformation deep-transformations tree nodedeep-transformationsinherited attributes deep-transformationssynthesized attributes  Safe-Inferred:{  !!""#$%&'()*+,-./0123456789::;<=>?@@ABCDEEFGHIJKKIJLMNOPQRSTUVWXXYZZ[L\]^_`abcdefghijklmnopqrstuvwxyz{|}~6789=>??AFBCD?67AF=>?BCD J I K               K  I  J L { q   _    z p   ^    y o   ]                          ! !                                                                         /deep-transformations-0.3-EATuLN1SgHdJEjPUviLx9ZTransformationTransformation.AGTransformation.DeepTransformation.FullTransformation.Deep.THTransformation.AG.DimorphicTransformation.AG.MonomorphicTransformation.Full.THTransformation.Rank2Transformation.ShallowTransformation.AG.GenericsTransformation.Shallow.THdeep-transformations Data.FunctorFunctor Bequether Synthesizer GHC.GenericsGenericSynthesizedFieldFoldable TraversableData.Functor.SumSumData.Functor.ProductProduct Data.Eithereither ComposeInner ComposeOuter TraversedFoldedMappedComposeAt$DomainCodomainapply$fTransformationEither$fTransformation(,)$fTransformationArrow $fAtEitherx$fAt(,)x $fAtArrowx $fAtComposex$fTransformationCompose $fAtMappedx$fTransformationMapped $fAtFoldedx$fTransformationFolded$fAtTraversedx$fTransformationTraversed applyDefaultapplyDefaultWithAttributesknit knitKeepingAllAttsallInhallSyn Attribution attributionAtts InheritedinhPreservingSemanticsRule Semantics Synthesizedsyn$fShowInherited$fShowSynthesizedfoldMap<$>traversefmapmapDownDefault mapUpDefaultfoldMapDownDefaultfoldMapUpDefaulttraverseDownDefaulttraverseUpDefaultInLInRPairfstsndNestunNestOnlyfromOnly eitherFromSum$fTraversabletOnly$fFoldabletOnly$fFunctortOnly$fDistributiveTYPEOnly!$fDistributiveTraversableTYPEOnly$fApplicativeTYPEOnly$fApplyTYPEOnly$fTraversableTYPEOnly$fFoldableTYPEOnly$fFunctorTYPEOnly$fTraversabletNest$fFoldabletNest$fFunctortNest$fTraversableTYPENest$fFoldableTYPENest$fApplicativeTYPENest$fApplyTYPENest$fFunctorTYPENest$fTraversabletProduct$fFoldabletProduct$fFunctortProduct$fDistributiveTYPEProduct$$fDistributiveTraversableTYPEProduct$fTraversableTYPEProduct$fFoldableTYPEProduct$fApplicativeTYPEProduct$fApplyTYPEProduct$fFunctorTYPEProduct$fTraversabletSum$fFoldabletSum $fFunctortSum$fTraversableTYPESum$fFoldableTYPESum$fFunctorTYPESum$fOrdSum$fEqSum $fShowSum $fDataSum $fOrdProduct $fEqProduct $fShowProduct $fDataProduct $fShowNest $fOrdNest$fEqNest $fDataNest $fShowOnly $fOrdOnly$fEqOnly $fDataOnly deriveAllderiveFoldable deriveFunctorderiveTraversablefullMapDefaulttraverseDefaultWithAttributesAutoFeeder FeederDomainKeep $fAtAutog $fAtFeederg $fAtKeepg$fAttributiontabgdeepshallow $fDataAtts$fFunctorAutog$fFunctorKeepg $fMonoidAtts$fSemigroupAtts $fShowAtts$fTransformationFeeder$fTraversableFeederg$fTraversableKeepg$fAttributiontagdeepshallowderiveDownFoldablederiveDownFunctorderiveDownTraversablederiveUpFoldablederiveUpFunctorderiveUpTraversableFoldMap Traversal $fAtFoldx$fAtMapx$fAtTraversalx $fFunctorMapg$fTransformationFold$fTransformationMap$fTransformationTraversal$fFunctortFlip$fFunctortIdentity$fFunctortConst$fFunctortProxy$fFunctortEmpty$fFoldabletFlip$fFoldabletIdentity$fFoldabletConst$fFoldabletProxy$fFoldabletEmpty$fTraversabletFlip$fTraversabletIdentity$fTraversabletConst$fTraversabletProxy$fTraversabletEmpty$fFunctortCompose$fAtFunctorComposea$fTransformationFunctorCompose$fFoldabletCompose$fAtFoldableComposea$fTransformationFoldableCompose$fTraversabletCompose$fAtTraversableComposea"$fTransformationTraversableComposebequestDefault foldedField mappedFieldpassDownbequest getFolded getMapped RevelationrevealsynthesizedField synthesis getTraversed$fApplicativeMapped$fAtAccumulatorx $fAtPassDowna$fAtReplicatora$fAtTraversera$fAttributionAutogds$fBequethertgArrowshallow $fEqFolded $fEqMapped $fEqTraversed$fFoldableMapped$fFoundFieldkaK1$fFoundFieldkaM1$fFunctorMapped$fFunctorTraversed-$fGenericSynthesizedFieldknameK1tgdeepshallow%$fGenericSynthesizerktgdeepshallow:*:$$fGenericSynthesizerktgdeepshallowM1%$fGenericSynthesizerktgdeepshallowM10$fMayHaveMonoidalFieldknamea:*:$fMayHaveMonoidalFieldknamea:+:$fMayHaveMonoidalFieldknameaM1$fMayHaveMonoidalFieldknameaM10$fMayHaveMonoidalFieldknameaM11$fMayHaveMonoidalFieldknameaM12$fMayHaveMonoidalFieldknameaf $fMonadMapped$fMonoidFolded$fMonoidMapped$fMonoidTraversed $fOrdFolded $fOrdMapped$fOrdTraversed$fSemigroupFolded$fSemigroupMapped$fSemigroupTraversed $fShowFolded $fShowMapped$fShowTraversed)$fSynthesizedFieldnameFoldedtgdeepshallow#$fSynthesizedFieldnameMappedtgdeepf&$fSynthesizedFieldnameTraversedtgdeepf$fSynthesizertgds$fTransformationAccumulator$fTransformationPassDown$fTransformationReplicator$fTransformationTraverserbaseData.Traversable Data.Foldable GHC.MaybeMaybe)rank2classes-1.5.4-ISpz0yvYd4UF7gqRgvxPFuRank2MayHaveMonoidalField AccumulatorPassDown Replicator TraverserGenericSynthesizedFieldGenericSynthesizertraversedField