js_of_ocaml 6.1.0 drops OCaml 4.12 and adds initial OCaml 5.4 support. In OCaml stdlib 5.4, List.take and List.drop now return [] on negative arguments rather than raising Invalid_argument.
Features
OCaml stdlib: Adds Set.S.is_singleton and Map.S.is_singleton to test whether a set or map holds exactly one element. Merged. #14118
OCaml stdlib (proposal): Proposes String.take, String.drop, String.span and reverse variants for splitting strings by magnitude. Open. #14125
odoc LaTeX backend: Adds --shorten-beyond-depth flag to abbreviate submodule names beyond a given nesting depth in generated LaTeX. Merged. #1337
Compatibility
odoc OCaml 5.4: Updates the odoc model for labelled and bivariant type parameters and the loader for the 5.4 AST. Merged. #1355
Releases
opam 2.4.0~rc1: First release candidate; signed binaries and archive available. Release notes
js_of_ocaml 6.1.0: Released 2025-07-04. Drops OCaml 4.12, adds initial OCaml 5.4 support, rewrites the inlining pass, adds --empty-sourcemap flag. Release notes
Fixes
OCaml stdlib (5.4): List.take and List.drop return [] on negative arguments instead of raising Invalid_argument. Merged. #14124
OCaml compiler: Fixes a spurious "Destructive substitutions are not supported for constrained types" error on non-destructive with type constraints. Merged. #14117
odoc type rendering: Adds missing parentheses around (_ as 'a) in type expressions, fixing invalid syntax in rendered output. Merged. #1358
js_of_ocaml codegen: Removes quadratic behaviour in the expression queue, cutting codegen time by up to 60% on large inputs. Merged. #2066
Eio posix: Fixes macOS and FreeBSD path-resolution errors; wraps openat in spawn_unix and enables O_RESOLVE_BENEATH on FreeBSD. Merged. PRs #809, #810
OxCaml Flambda2: Closes a mutable-unboxing miscompilation triggered by for-loop constructs. #2123