acc

Sequence optimized for monoidal construction and folding

https://github.com/nikita-volkov/acc

Version on this page:0.1.3
LTS Haskell 22.14:0.2.0.3
Stackage Nightly 2024-03-29:0.2.0.3
Latest on Hackage:0.2.0.3

See all snapshots acc appears in

MIT licensed and maintained by Nikita Volkov
This version can be pinned in stack with:acc-0.1.3@sha256:8c63dda349e4b37bb8de1977bc35db05d77c34fa85becb09dcb7e29bc00d52f9,3806

Module documentation for 0.1.3

Used by 1 package in nightly-2021-10-20(full list with versions):

Data structure intended for accumulating a sequence of elements for later traversal or folding. Useful for implementing all kinds of builders on top.

The benchmarks show that for the described use-case it is on average 2 times faster than DList and Seq, is on par with list when you always prepend elements and is exponentially faster than list when you append.