This module provides tools for compiling
QDiagrams into a more
convenient and optimized tree form, suitable for use by backends.
- data RNode b v a
- type RTree b v a = Tree (RNode b v a)
- toRTree :: HasLinearMap v => QDiagram b v m -> RTree b v Annotation
- toDTree :: HasLinearMap v => QDiagram b v m -> Maybe (DTree b v Annotation)
- fromDTree :: HasLinearMap v => DTree b v Annotation -> RTree b v Annotation
Tools for backends
|RStyle (Style v)|
A style node.
|RFrozenTr (Transformation v)|
A "frozen" transformation, i.e. one which
was applied after a call to
|RPrim (Transformation v) (Prim b v)|
A primitive, along with the (non-frozen) transformation which applies to it.
QDiagram into a raw tree.
DTree to an
RTree which can be used dirctly by backends.
DTree includes nodes of type
DTransform (Split (Transformation v));
RTree the frozen part of the transform is put in a node of type
RFrozenTr (Transformation v) and the unfrozen part is pushed down until
it is either frozen or reaches a primitive node.