Postmodern immutable and persistent data structures for C++ — value semantics at scale
2.9k
Stars
203
Forks
46
Open issues
30
Contributors
AI Analysis
Immer is a C++ library providing persistent and immutable data structures (vectors, maps, sets) using advanced techniques like HAMT and RRB-trees, enabling functional programming patterns and concurrent-safe code in C++. It serves specialized systems programming and interactive application developers who need structural sharing and value semantics at scale; it is not a general-purpose alternative to STL containers for most applications.
Inferred from signals mentioned in the README (tests, CI, type safety) — not a review of the actual code.
AI's overall editorial judgment — not an average of the bars above, can weigh other factors too.
C++ persistent data structures for immutable-first concurrent and interactive systems
Immer is a header-only C++ library providing efficient persistent (structural-sharing) and immutable data structures—vectors, maps, sets—designed to enable functional programming patterns in C++. Built for systems programming contexts requiring value semantics, concurrency safety, and undo/redo capabilities. Adoption appears limited to specialized domains: interactive UI frameworks, state management libraries, and research contexts where immutability-by-default solves architectural problems. Not widely adopted in mainstream C++ development.
Created in 2016 by Juan Pedro Bolívar (Sinusoidal Engineering), motivated by the functional programming movement in languages like Clojure and JavaScript frameworks like Immutable.js. Formalized through academic publication (ICFP'17 paper 'Persistence for the masses'). Represents the deliberate transfer of functional data structure techniques to C++ where they remain niche.
Project gained initial attention circa 2016–2018 through conference talks (CppCon'17) and academic credibility. Growth plateaued: 2,857 stars (modest for a 10-year-old project) with near-zero 7-day gain suggests stable but not expanding adoption. Last push 2026-07-05 shows active maintenance, but velocity appears low. Adoption likely constrained by the cultural mismatch between C++ idioms and functional immutable design patterns.
README names two downstream projects: Ewig (didactic text editor) and Lager (Redux-like state management library), both authored by the same developer, suggesting limited third-party adoption verification. Adoption not verified beyond the author's own ecosystem. No public case studies, corporate endorsements, or evidence of use in widely-known production systems documented in README.
Header-only library using C++ templates and policy-based design (mentioned in README). Appears to implement persistent data structures with structural sharing to enable efficient cloning. Likely uses tree-based or trie-based internals common in Clojure-inspired designs, though source code inspection not available. README emphasizes cache-friendly memory layout abstraction.
README includes CodeCov badge and references GitHub Actions CI/test workflows, suggesting automated testing is in place. No explicit coverage percentage documented in excerpt, but presence of badges indicates active test infrastructure.
Last push 2026-07-05 (5 days before analysis date) indicates active, recent maintenance. Created 2016, so 10 years old. Steady maintenance pattern likely, but low star velocity (0 in last week) and modest fork count (203) suggest limited contributor base. No evidence of accelerating activity.
ADOPT IF: building interactive (undo/redo), concurrent, or Redux-like state management systems in C++ where value semantics and immutability-by-default significantly reduce bugs and reasoning complexity. AVOID IF: you are optimizing for team familiarity, hiring pipeline, or need battle-tested production support—mainstream C++ teams rarely use functional immutable patterns and would face a learning curve and limited ecosystem. MONITOR IF: your project currently uses mutable containers and struggles with concurrency bugs or correctness, but you want to validate the fitness of immutable data structures before committing; test with Immer in a non-critical subsystem first.
Independent dimensions
Mainstream potential
2/10
Technical importance
7/10
Adoption evidence
2/10
- Adoption not verified beyond the author's own ecosystem; limited public production evidence means fewer reported bugs and fewer community solutions to edge cases.
- Small contributor base (203 forks, low recent star velocity) suggests limited capacity to address issues quickly or scale support if adoption grows.
- C++ culture remains mutable-first; developers unfamiliar with functional programming patterns may find the API counterintuitive, limiting team adoption even if technically sound.
- No integration with mainstream C++ frameworks (Qt, Electron, game engines, web frameworks). Narrow addressable market limits ecosystem growth.
- Header-only library means slow compilation times and potential code bloat; not suitable for all deployment contexts (embedded, resource-constrained environments).
Immer will likely remain a specialized, well-maintained tool for niche domains (interactive UI frameworks, Redux-like state management, concurrent systems research) without significant mainstream adoption. Maintenance will probably continue at low steady state; growth unlikely unless C++ culture shifts toward functional paradigms or a major tech company publicly endorses it.
Newsletter
Get analyses like this every Monday
Free weekly digest of the most interesting open-source discoveries.
Languages
Information
- Website
- https://sinusoid.es/immer
- Language
- C++
- License
- BSL-1.0
- Last updated
- 5d ago
- Created
- 120mo ago
- Analyzed with
- anthropic/claude-haiku-4-5
Stars over time
Contributors over time
Top 100 contributors only — repos with more will plateau at 100.
Open issues
Can immer::vector support incomplete types with sizes known at compile time?
Forward declaration fails with immer::map when it used to work
Explore ClojureDart-style hash maps
3 tests fail on powerpc: flex_vector-fuzzed-0 (Failed), flex_vector_transient-B3-BL0 and flex_vector_transient-gc (Bus error)
Tests use libfmt headers without requiring or checking for its presence
Top contributors
Recent releases
Similar repos
No similar repos indexed yet — similarity data is generated after AI enrichment.
Mutable-first, does not provide structural sharing or immutability guarantees. More widely adopted and familiar to C++ developers. Immer trades off adoption for correctness guarantees suited to concurrent and interactive use cases.
Immer ports functional immutable patterns to C++. Immutable.js is massively adopted in React/Redux ecosystems. Immer lacks similar integrations and ecosystem, serving a much smaller addressable market.
Native, language-level support for immutable structures. Immer is a library workaround for C++, which lacks first-class language support. Adoption in C++ likely lower because patterns are less idiomatic.
Offers efficient C++ containers but remains mutable-first. Does not target immutable, functional paradigms. Folly is more widely used in industry because it aligns with C++ conventions.
General-purpose C++ utilities without focus on immutability. Widely adopted. Immer is a specialized tool solving a specific architectural problem, not a replacement.