Package

purescript-data-algebrae

Repository
i-am-tom/purescript-data-algebrae
License
MIT
Uploaded by
i-am-tom
Published on
2018-06-10

Intro

This library provides some basic [1] mutation-only [2] reified [3] operations for working with common data types in PureScript, as well as some convenience functions for generating plans. What does that mean?

[1]. Basic means that these are literally just data structures. The docs on Pursuit will tell you everything you need, as each constructor of the data type represents each possible action.

[2]. Mutation-only means that none of these allow you to access the data. This is a deliberate choice: your interpreter implementations can be written safe in the knowledge that none of the intermediate state is actually required externally, so it doesn't need to be preserved. If we care about performance, this means that we are free to write stateful interpreters that modify values in place using the ST operations or even a Ref.

[3]. Reified is a scary word that means "we represent our functions as a data type". We've lifted the idea of our computation into data, and thus made it totally pure!

Contributing

PRs, PRs, PRs! All welcome - this library will be biased by what I need (most likely for Panda, but I would be delighted if anyone wanted to add other structures or better tests!

Modules
Data.Algebra.Array
Data.Algebra.Map
Data.Algebra.Set
Dependencies