An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

persistent-vector

This package provides persistent vectors based on array mapped tries. The implementation is based on the persistent vectors used in clojure, but in a Haskell-style API. The API is modeled after Data.Sequence from the containers library. Technically, the element-wise operations are O(log(n)), but the underlying tree cannot be more than 7 or 8 levels deep so this is effectively constant time. One change from the clojure implementation is that this version supports O(1) slicing, though it does cheat a little. Slices retain references to elements that cannot be indexed. These extra references (and the space they occupy) can be reclaimed by shrinking the slice. This seems like a reasonable tradeoff, and, I believe, mirrors the behavior of the vector library. Highlights: O(1) append element, indexing, updates, length, and slicing Reasonably compact representation

Ecosystem
hackage.haskell.org
Latest Release
0.2.0
over 5 years ago
Versions
5
Downloads
3,703 total
Dependent Packages
1
0.2.0
Published: over 5 years ago
Registry - Download
0.1.1
Published: almost 11 years ago
Registry - Download
0.1.0.3
Published: almost 11 years ago
Registry - Download
0.1.0.1
Published: over 13 years ago
Registry - Download
0.1.0.0
Published: over 13 years ago
Registry - Download
Links
Registry hackage.haskell.org
Source Repository
JSON API View JSON
CodeMeta codemeta.json
Package Details
PURL pkg:hackage/persistent-vector
spec
License BSD-3-Clause
First Release over 13 years ago
Last Synced 9 days ago
Repository
Stars 27 on GitHub
Forks 4 on GitHub
Rankings on hackage.haskell.org
Dependent packages Top 6.0%