Skip to content

Oxcaml 5.4.0 ox9 - #1520

Closed
avsm wants to merge 9 commits into
ocaml:masterfrom
avsm:oxcaml-5.4.0-ox9
Closed

avsm wants to merge 9 commits into
ocaml:masterfrom
avsm:oxcaml-5.4.0-ox9

Conversation

@avsm

@avsm avsm commented Nov 6, 2026

Copy link
Copy Markdown
Member

This rebases oxcaml/odoc to work with the newly released oxcaml.5.4.0+ox9 oxcaml/opam-repository#66 /cc @dra27 @jonludlam

lukemaurer and others added 9 commits November 6, 2026 15:32
Under OxCaml the partial application [Buffer.add_string buf] is a
stack-allocated closure, which cannot be captured by [flush].  The same
change is already in src/search/odoc_html_frontend.ml.

This is what is left of "Adapt to 5.2.0minus-39 compiler-libs" once it is
rebased: master already carries the compiler-libs changes it made.

Co-Authored-By: Claude Fable 5 <[email protected]>
Co-Authored-By: Claude Fable 5.1 <[email protected]>
@jonludlam

Copy link
Copy Markdown
Member

Thanks! this does a bit more than just update, there's a bit of nice new functionality too.

@Leonidas-from-XIV

Copy link
Copy Markdown
Member

Pinging @art-w on this as I believe he has been looking into the new OxCaml release as well (disregard if I misremembered).

@dra27-js

dra27-js commented Nov 9, 2026

Copy link
Copy Markdown

Cursory drive-by - unless there's an amazingly compelling reason to do so, I wouldn't encode any kind of support for older versions of OxCaml (cf. realworldocaml/mdx#484) - I expect that the various tests for 5.4 should just be #if... OXCAML. (I'd then just update the conflicts clause in odoc.opam)

Alizter added a commit to Alizter/dune that referenced this pull request Nov 11, 2026
Use the regular odoc and odoc-parser package builders with the upstream
base and immutable diff for ocaml/odoc#1520. Share these pins with opam
CI, and remove the local OxCaml 5.4 compatibility patch. Stamp the
snapshot version consistently in sources and expected outputs.

Signed-off-by: Ali Caglayan <[email protected]>
Alizter added a commit to Alizter/dune that referenced this pull request Nov 11, 2026
Pin the opam release to ox9 and the latest tagged compiler to ox15.
Use the regular odoc and odoc-parser builders with the upstream base and
immutable diff for ocaml/odoc#1520 instead of a local compatibility
patch. Stamp the snapshot version in sources and expected outputs.

Signed-off-by: Ali Caglayan <[email protected]>
@avsm

avsm commented Nov 11, 2026

Copy link
Copy Markdown
Member Author

@dra27-js yes that 5.2 ifdef was convenient while I was porting, but I'm full 5.4.0+ox9 now as well!

Comment on lines +17 to +18
pos_cnum = loc.loc_start.pos_cnum ;
pos_lnum = loc.loc_start.pos_lnum

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these meant to be loc.loc_end?

Comment thread src/loader/odoc_loader.ml
let source_loc_jane =
match sourcefile with
| Some (Some file, _, build_dir) ->
Some {Odoc_model.Lang.Source_loc_jane.filename = build_dir ^ "/" ^ file ; line_number = 1}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can file ever be absolute? If so, then this is incorrect.

This logic is duplicated with src/model/lang.ml.

This was referenced Nov 18, 2026
Alizter added a commit to ocaml/dune that referenced this pull request Nov 25, 2026
Update both Nix and opam CI to OxCaml `5.4.0-ox9`, sharing
compiler/repository pins and the upstream odoc port from
ocaml/odoc#1520. Update the affected integration expectations and keep
the OxCaml patch guards enabled. Formatting and unrelated CI cleanups
remain separate follow-ups.

Follows merged #16968, #16985, #16990, and #16994.
@jonludlam

Copy link
Copy Markdown
Member

This was superseded by the pair #1526 and #1527 that are both now merged. Thanks everyone!

@jonludlam jonludlam closed this Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants