calligraphy-0.1.3: HIE-based Haskell call graph and source code visualizer
Safe HaskellNone
LanguageHaskell2010

Calligraphy.Phases.NodeFilter

Description

This modules manages the two ways we remove nodes from a graph; collapsing and hiding.

Collapsing means absorbing a node's descendants into itself, including all edges.

Hiding means removing a node (and its descendants), moving the edges to the node's parent, if a parent exist.

There's also the special option --collapse-modules. It's undeniably a little hacky, but for now this is the best home for that functionality. Functionality-wise, it's still essentially just collapsing nodes into one another. The thing that makes it hacky is that it then uses a value node to represent a module. This is not actually a huge deal, because no other module actually cares about the node type, but it's something to watch out for. There's more design discussion on https://github.com/jonascarpay/calligraphy/pull/5

Documentation