parazoa

Immutable, persistent data structures

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version Unknown
License Public Domain
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:24

Installation

nimble install parazoa
choosenim install parazoa
git clone https://github.com/paranim/parazoa

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
parazoa - - - - - - -

Source

Repository https://github.com/paranim/parazoa
Homepage https://github.com/paranim/parazoa
Registry Source nimble_official

README

An immutable, persistent Map, Set, and Vec for Nim, based on and inspired by the ones in Clojure.

Read the API docs and check out the tests for examples of how to use them.

Persistent data structures provide immutability without any expensive cloning, thanks to structural sharing. The basic design comes from Phil Bagwell's HAMT (hash array mapped trie), first made immutable by Rich Hickey in Clojure.

Why use persistent data structures in Nim? It's commonly believed that they're slow, but that depends on your use case. Do you find yourself making copies of your data defensively so you can retain its original value after mutating it?

Persistent data structures may improve your performance, since "cloning" them is just a matter of copying a ref! They can also be faster at equality comparisons, because if they have the same underlying address, we know they are equal and can short-circuit the comparison.