Skip to content

Commit 0537a33

Browse files
kit-ty-katesmorimoto
authored andcommitted
Add support for OCaml 5.3
1 parent 2dd7ddf commit 0537a33

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

.github/workflows/workflow.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ jobs:
2020
ocaml-compiler:
2121
- "4.14"
2222
- "5.2"
23+
- "5.3"
2324

2425
runs-on: ${{ matrix.os }}
2526

eliom.opam

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ homepage: "https://ocsigen.org/eliom/"
1818
bug-reports: "https://github.com/ocsigen/eliom/issues"
1919
depends: [
2020
"dune" {>= "3.18"}
21-
"ocaml" {>= "4.12" & < "5.3"}
21+
"ocaml" {>= "4.12"}
2222
"ocamlfind"
2323
"ppx_deriving"
2424
"ppxlib" {>= "0.15"}

src/ppx/ppx_eliom_utils.ml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,9 +453,18 @@ module Cmo = struct
453453
in
454454
type_of_out_type ty
455455

456+
[%%if ocaml_version >= (5, 3, 0)]
457+
let typ ty =
458+
let ty =
459+
Out_type.prepare_for_printing [ty];
460+
Out_type.tree_of_typexp Type_scheme ty
461+
in
462+
type_of_out_type ty
463+
[%%else]
456464
let typ ty =
457465
let ty = Printtyp.tree_of_type_scheme ty in
458466
type_of_out_type ty
467+
[%%endif]
459468

460469
let find err loc =
461470
let {Lexing.pos_fname; pos_cnum; _} = loc.Location.loc_start in

0 commit comments

Comments
 (0)