Oriel — AI & technology worth noticing, every day.

Nim version 2.4.0 released

Web page · https://nim-lang.org/blog/2026/10/28/nim-240.html

First seen by Oriel on .

AI summary

Nim 2.4.0 is a major stable release adding SSO strings, parallel incremental compilation, thread-safe cycle collection, concise sum types, and declared cyclic imports.

  • The new --strings:sso backend improves string efficiency and introduces readRawData, readRawDataStable, beginStore, and endStore APIs compatible across memory managers and Nimony.
  • With --ic:on, multiprocess incremental compilation reduced a 16-core Nim compiler build from 31 seconds to 25 seconds, though compile-time globals may require changes.
  • The --mm:yrc collector supports shared references and cycles spanning threads without stop-the-world phases, but benchmarks show twice ORC's runtime and memory usage.
  • Sum types remove explicit discriminator enums, preserve case-object layout and performance, support generics, and require exhaustive pattern matching that prevents FieldDefect from wrong-branch access.
  • Imports marked {.cyclic.} form groups checked in phases, allowing cross-module types and procedures regardless of declaration order; unannotated cycles are now deprecated.

#nim #memory management #incremental compilation #sum types

Generated by gpt-5.6-sol. Check the original for details.

Metric trends

Last 30 days · Up to 120 recorded samples per source and metric, with reposts kept separate · First and latest retained

Points

Score reported by the source.

  • Lobsters: 12, latest observation ; +11 over observed period since

Comments

Comment count reported by the source.

  • Lobsters: 0, latest observation ; 0 over observed period since

Aliases

SourceExternal IDURL
Lobstersvfllmehttps://nim-lang.org/blog/2026/10/28/nim-240.html Read discussion