Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compiler packages for the OCaml 5.3.0~beta1 #26822

Merged
merged 1 commit into from
Nov 4, 2024

Conversation

Octachron
Copy link
Member

This PR adds three packages for the first beta release of OCaml 5.3.0:

  • the usual ocaml-base--compiler and ocaml-variants packages
  • the newish ocaml-compiler package

Compared to the first alpha, this beta includes 3 runtime fixes, 2 type system fix and a handful numbers of fixes for the runtime event library. This beta also adds a new -keywords compatibility flag in order to help compiling old code that are using the new keyword effect as a standard identifier.


Changes compared to the first alpha:

Runtime bug fixes

  • (13502): Fix misindexing related to Gc.finalise_last that could prevent
    finalisers from being run.
    (Nick Roberts, review by Mark Shinwell)

  • (13402), (13512), (13549), (13553): Revise bytecode implementation of callbacks
    so that it no longer produces dangling registered bytecode fragments.
    (Xavier Leroy, report by Jan Midtgaard, analysis by Stephen Dolan,
    review by Miod Vallat)

  • (13520): Fix compilation of native-code version of systhreads. Bytecode fields
    were being included in the thread descriptors.
    (David Allsopp, review by Sébastien Hinderer and Miod Vallat)

Type system bug fixes

  • (13579), (13583): Unsoundness involving non-injective types + gadts
    (Jacques Garrigue, report by @v-gb,
    review by Richard Eisenberg and Florian Angeletti)

  • (13388), (13540): raises an error message (and not an internal compiler error)
    when two local substitutions are incompatible (for instance module type S:=sig end type t:=(module S))
    (Florian Angeletti, report by Nailen Matschke, review by Gabriel Scherer, and
    Leo White)

Compiler CLI

  • (13471): add -keywords <version?+list> flag to define the list of keywords
    recognized by the lexer, for instance -keywords 5.2 disable the effect
    keyword.
    (Florian Angeletti, review by Gabriel Scherer)

Runtime event library fixes

  • (13419): Fix memory bugs in runtime events system.
    (B. Szilvasy and Nick Barnes, review by Miod Vallat, Nick Barnes,
    Tim McGilchrist, and Gabriel Scherer)

  • (13407): Add Runtime_events.EV_EMPTY_MINOR
    (Thomas Leonard)

  • (13522): Confirm runtime events ring is still active after callback.
    (KC Sivaramakrishnan, review by Sadiq Jaffer and Miod Vallat)

  • (13529): Do not write to event ring after going out of stw participant set.
    (KC Sivaramakrishnan, review by Sadiq Jaffer)

Documentation

  • (13424): Fix Gc.quick_stat documentation to clarify that returned fields
    live_words, live_blocks, free_words, and fragments are not zero.
    (Jan Midtgaard, review by Damien Doligez and KC Sivaramakrishnan)

  • (13440): Update documentation of Gc.{control,get,set} to reflect fields
    not currently supported on OCaml 5.
    (Jan Midtgaard, review by Gabriel Scherer)

  • (13469), (13474), (13535): Document that [Hashtbl.create n] creates a hash table
    with a default minimal size, even if [n] is very small or negative.
    (Antonin Décimo, Nick Bares, report by Nikolaus Huber and Jan Midtgaard,
    review by Florian Angeletti, Anil Madhavapeddy, Gabriel Scherer,
    and Miod Vallat)

Standard library internal fix

  • (13543): Remove some String-Bytes conversion from the stdlib to behave better
    with js_of_ocaml
    (Hugo Heuzard, review by Gabriel Scherer)

Toplevel bug fix

  • (13263), (13560): fix printing true and false in toplevel and error
    messages (no more unexpected #true)
    (Florian Angeletti, report by Samuel Vivien, review by Gabriel Scherer)

Compiler internals

  • (13391), (13551): fix a printing bug with -dsource when using
    raw literal inside a locally abstract type constraint
    (i.e. let f: type \#for. ... )
    (Florian Angeletti, report by Nick Roberts, review by Richard Eisenberg)

@shonfeder
Copy link
Collaborator

The only CI error is

Warning in ocaml-compiler.5.3.0~beta1: The package has a dune-project file but no explicit dependency on dune was found.

And I suspect this is not relevant for the compiler.

Do we need to check anything else, or is this ready for merge?

@Octachron
Copy link
Member Author

The dune linter error is indeed not relevant (the dune file in the compiler tree is exclusively for development purposes).

@mseri
Copy link
Member

mseri commented Nov 4, 2024

Thanks!

@mseri mseri merged commit 9048aac into ocaml:master Nov 4, 2024
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants