The release of OCaml version 5.0.0 is imminent. As a final step before the release,
we are publishing a release candidate that you can test while waiting for the release
in the upcoming weeks.
If you find any bugs, please report them here:
Compared to the second beta release, this release contains one toplevel bug fix
and a minor type system fix.
If you are interested by the bug fixes beyond the new multicore runtime, the
full change log for OCaml 5.0.0 is available at:
ocaml/Changes at 5.0 · ocaml/ocaml · GitHub
A short summary of the two changes since the second beta release is also available below.
This release candidate will be followed shortly by a release candidate for OCaml 4.14.1 .
This updated minor version for OCaml 4.14 will mirror the safe bug fixes from the OCaml 5.0
branch.
Installation instructions
The base compiler can be installed as an opam switch with the following commands on opam 2.1:
opam update
opam switch create 5.0.0~rc1
For previous version of opam, the switch creation command line is slightly more verbose:
opam update
opam switch create 5.0.0~rc1 --repositories=default,beta=git+https://github.com/ocaml/ocaml-beta-repository.git
It might be also interesting to check the new support for parallelism by installing the domainslib library with
opam install domainslib
The source code for the release candidate is available at these addresses:
https://github.com/ocaml/ocaml/archive/5.0.0-rc1.tar.gz
https://caml.inria.fr/pub/distrib/ocaml-5.0/ocaml-5.0.0~rc1.tar.gz
Fine-tuned compiler configuration
If you want to tweak the configuration of the compiler, you can switch to the option variant with:
opam update
opam switch create <switch_name> ocaml-variants.5.0.0~rc1+options <option_list>
where <option_list>
is a comma separated list of ocaml-option-*
packages. For instance, for a flambda and no-flat-float-array switch:
opam switch create 5.0.0~rc1+flambda+nffa ocaml-variants.5.0.0~rc1+options ocaml-option-flambda ocaml-option-no-flat-float-array
The command line above is slightly more complicated for opam versions anterior to 2.1:
opam update
opam switch create <switch_name> --packages=ocaml-variants.5.0.0~rc1+options,<option_list> --repositories=default,beta=git+https://github.com/ocaml/ocaml-beta-repository.git
In both cases, all available options can be listed with “opam search ocaml-option”.