[ANN] ppxlib.0.36.0

The ppxlib team is happy to announce the release of ppxlib.0.36.0!

A full account of the changes can be found on the 0.36.0 release.

OCaml 5.2 Internal AST

The main change in this release is that the internal AST used in ppxlib is now the same as OCaml 5.2’s AST. Previously it was 4.14.0. The internal AST dictates what features your ppx can and cannot generate. To avoid confusion, this does not mean ppxlib only supports OCaml 5.2 and greater. Ppxlib still supports compilers starting at 4.08.0.

The bump to 5.2 has caused a lot of reverse dependencies to break as the 5.2 AST represents functions differently (see the Syntactic Function Arity RFC). Many patches have already been sent to users of ppxlib in the past few months, but quite a few still remain.

:warning: Ppx authors are advised to read the wiki entry for upgrading to ppxlib.0.36.0. :warning:

Please do not hesitate to reach out if you need any help upgrading to ppxlib.0.36.0.

Other Changes

  • Change Location.none to match the compiler’s Location.none as of OCaml
    4.08.
  • New ways to create context free rules using floating expansions – see #560 for the details.
  • Add a -raise-embedded-errors flag to the driver. Setting this flag raises the first
    ocaml.error embedded in the final AST.
  • Export Ast_pattern.fail making it easier to write new pattern-matchers.
  • Improvements to Ast_traverse.sexp_of to be more concise.

Do read the changes entry/release for all of the acknowledgments – thank you to everyone who contributed to this release of ppxlib! A special thanks from me to @NathanReb who has been a massive help getting this work over the line.

Thank you to Tarides and Jane Street for funding my time on this release of ppxlib.

5 Likes