Portability | non-portable (uses Data.Generics.Basics) |
---|---|
Stability | experimental |
Maintainer | rasfar@gmail.com |
Safe Haskell | None |
This package provides SYB shape support: generic mapping to homogeneous types, and related features. Complements existing Uniplate and TH shape libraries. See http://www.fremissant.net/shape-syb for more information.
The present module provides support for staged GHC AST types.
One you have a
, Homo
rHetero
, or
, the rest of
the API in Shape.SYB and Shape.SYB.Filter is applicable.
Bi
r
- ghomStaged :: forall r d. Data d => Stage -> r -> GenericQ r -> d -> Homo r
- ghomStagedK :: forall r d. Data d => Stage -> r -> (r -> r -> r) -> GenericQ r -> d -> Homo r
- ghomDynStaged :: forall d. Data d => Stage -> d -> Hetero
- ghomBiStaged :: forall r d. Data d => Stage -> r -> GenericQ r -> d -> Bi r
- data GHC_AST_HOLE
- shapeOfStaged :: forall d. Data d => Stage -> d -> Shape
- shapeOfStaged_ :: forall d. Data d => Stage -> d -> Shape
- sizeOfStaged :: forall d. Data d => Stage -> d -> Int
- symmorphicStaged :: forall d1 d2. (Data d1, Data d2) => Stage -> d1 -> d2 -> Bool
- weightedShapeOfStaged :: forall d. Data d => Stage -> d -> Homo Int
- data Stage
- = Parser
- | Renamer
- | TypeChecker
Staged shape functions
ghomDynStaged :: forall d. Data d => Stage -> d -> HeteroSource
Uses Data.Dynamic to support mutiple types homogeneously.
ghomBiStaged :: forall r d. Data d => Stage -> r -> GenericQ r -> d -> Bi rSource
ghomBiStaged
s f x =zipRose
(ghomDynStaged
s x) (ghomStaged
s f x)
shapeOfStaged :: forall d. Data d => Stage -> d -> ShapeSource
shapeOfStaged_ :: forall d. Data d => Stage -> d -> ShapeSource
sizeOfStaged :: forall d. Data d => Stage -> d -> IntSource
symmorphicStaged :: forall d1 d2. (Data d1, Data d2) => Stage -> d1 -> d2 -> BoolSource
Compare two rose trees for shape equality.