We have the pleasure of celebrating the anniversary of the first powered flight in Europe by announcing the release of OCaml 5.5.2.
OCaml 5.5.2 fixes various minor security issues, two rare miscompilations, a configuration issue with future versions of macOS, and one runtime events library issue.
Overall, if you were already using any versions of OCaml 5.5, we are advising you to switch to OCaml 5.5.2 .
The full list of bug fixes is available below for more details.
Happy hacking,
– Florian Angeletti, for the OCaml team.
Installation Instructions
The base compiler can be installed as an opam switch with the following commands:
opam update
opam switch create 5.5.2
The source code for the release is also directly available on:
- GitHub: https://github.com/ocaml/ocaml/archive/5.5.2.tar.gz
- Inria archive: https://caml.inria.fr/pub/distrib/ocaml-5.5/ocaml-5.5.2.tar.gz
Bug Fixes
-
#15045: Atomic loads whose results are unused should not be removed
during dead-code elimination.
(Xavier Clerc, review by Steven Dolan and KC Sivaramakrishnan) -
#15067, #15071: Fix detection of functions available in the future on macOS.
(Antonin Décimo, review by Nicolás Ojeda Bär and Damien Doligez) -
#15112, OSEC-2026-22:
Unix.map_file: protect against overflow
when computing the data size.
(Xavier Leroy and Nicolás Ojeda Bär, review by Nicolás Ojeda Bär
and Edwin Török) -
#15113, OSEC-2026-21:
Str.string_partial_match: make sure captured groups
are valid.
(Xavier Leroy, review by Nicolás Ojeda Bär and Edwin Török) -
#15115, OSEC-2026-23: Fix multiple issues in demarshaling
(Marshal.from_{channel,string,bytes})
(Xavier Leroy, review by Nicolás Ojeda Bär) -
#15133, OSEC 2026-24: Multiple issues in command quoting on Windows
(Xavier Leroy and Nicolás Ojeda Bär, review by Nicolás Ojeda Bär) -
#15119, OSEC-2026-25: Harden decoding of runtime events messages from
ring buffers.
(Sadiq Jaffer, report by Hannes Mehnert, review by Olivier Nicole and
Edwin Török) -
#15177, OSEC-2026-26: Maintain custom events cache integrity.
(Sadiq Jaffer, report by Hannes Mehnert, review by Edwin Török) -
#15043, #15076: runtime events library, fix an infinite loop when a user
event is larger than half the ring buffer.
(Tim McGilchrist, review by Sadiq Jaffer) -
#15185, #15187: fix a pattern-matching miscompilation on certain
combinations of immediate ranges and redundant patterns
(Gabriel Scherer, report by Alperer Keleş,
review by Vincent Laviron and Florian Angeletti)