Sums/products/lists/trees which can be extended in other modules

Latest on Hackage:

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

PublicDomain licensed and maintained

Extensible lists: Add to a list at compile-time in many modules, which do not necessarily know each other, and then collect it into a single list in a module depending on all of them (possibly indirectly).

Extensible products: It is a record in which new fields can be added anywhere including in different modules; dependent defaults are supported, so it is still possible to make a value of such a type.

Extensible sums: Type with choices; new choices can be added anywhere including in other modules (which do not need to know each other). The operations on them are also freely extensible in the similar way.

Extensible trees: You can make a tree out of types, and have a value at each node. New nodes can be added anywhere if you have access to the node which will become the new node's parent.

Used by 1 package:
comments powered byDisqus