arximboldi

arximboldi/immer

C++ BSL-1.0 Dev Tools

Postmodern immutable and persistent data structures for C++ — value semantics at scale

2.9k stars
203 forks
active
GitHub

2.9k

Stars

203

Forks

46

Open issues

30

Contributors

v0.9.1 13 Jan 2026

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.

Dev Tools Library Discovery value: 7/10
Documentation 8/10
Activity 9/10
Community 7/10
Code quality 8/10

Inferred from signals mentioned in the README (tests, CI, type safety) — not a review of the actual code.

Overall score 8/10

AI's overall editorial judgment — not an average of the bars above, can weigh other factors too.

immutable-data-structures persistent-collections functional-programming c++14 structural-sharing
Actively maintained Well documented Niche/specialized use case Production ready
Deep Analysis · Based on README and public signals
3h ago

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.

Origin

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.

Growth

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.

In production

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.

Code analysis
Architecture

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.

Tests

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.

Maintenance

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.

Honest verdict

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

Risks
  • 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).
Prediction

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.

0 found this helpful

Newsletter

Get analyses like this every Monday

Free weekly digest of the most interesting open-source discoveries.

Languages

C++
76.9%
JavaScript
20.4%
CMake
0.9%
Python
0.6%
Nix
0.4%
Scheme
0.2%
Scala
0.2%
Clojure
0.1%

Information

Language
C++
License
BSL-1.0
Last updated
5d ago
Created
120mo ago
Analyzed with
anthropic/claude-haiku-4-5

Stars over time

Loading…

Contributors over time

Top 100 contributors only — repos with more will plateau at 100.

Loading…

Similar repos

No similar repos indexed yet — similarity data is generated after AI enrichment.

vs. alternatives
Boost.Container (standard C++ approach)

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.

Immutable.js (JavaScript)

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.

Clojure/Scala persistent collections (JVM languages)

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.

Folly (Facebook's C++ library)

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.

Abseil (Google's C++ library)

General-purpose C++ utilities without focus on immutability. Widely adopted. Immer is a specialized tool solving a specific architectural problem, not a replacement.