File tree Expand file tree Collapse file tree 10 files changed +17
-35
lines changed Expand file tree Collapse file tree 10 files changed +17
-35
lines changed Original file line number Diff line number Diff line change 49
49
50
50
# Remove this pin once a compatible version of Merlin has been released
51
51
- name : Pin dev Merlin
52
- run : opam --cli=2.1 pin --with-version=5.4 -503 https://github.com/ocaml/merlin.git#main
52
+ run : opam --cli=2.1 pin --with-version=5.5 -503 https://github.com/ocaml/merlin.git#main
53
53
54
54
- name : Build and install dependencies
55
55
run : opam install .
90
90
91
91
# Remove this pin once a compatible version of Merlin has been released
92
92
- name : Pin dev Merlin
93
- run : opam --cli=2.1 pin --with-version=5.4 -503 https://github.com/ocaml/merlin.git#main
93
+ run : opam --cli=2.1 pin --with-version=5.5 -503 https://github.com/ocaml/merlin.git#main
94
94
95
95
- name : Install dependencies
96
96
run : |
Original file line number Diff line number Diff line change 14
14
- Fix ` inlay-hint ` for function parameters (#1515 )
15
15
- More precise diagnostics in the event of a failed identifier search (` Definition_query ` ) (#1518 )
16
16
- Remove ` ocamlformat ` application after ` destruct ` (that remove some useful parenthesis) (#1519 )
17
+ - Make compatible with Yojson 3.x by removing ` Tuple ` and ` Variant ` (#1534 )
17
18
18
19
# 1.22.0
19
20
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ possible and does not make any assumptions about IO.
31
31
" )
32
32
( depends
33
33
( jsonrpc ( = :version ) )
34
- ( yojson ( < 3 .0.0 ) )
34
+ yojson
35
35
( ppx_yojson_conv_lib ( >= " v0.14" ) )
36
36
( cinaps :with -test)
37
37
( ppx_expect ( and ( >= v0.17.0) :with -test) )
@@ -45,7 +45,7 @@ possible and does not make any assumptions about IO.
45
45
(synopsis " LSP Server for OCaml" )
46
46
( description " An LSP server for OCaml." )
47
47
( depends
48
- ( yojson ( < 3 .0.0 ) )
48
+ yojson
49
49
( base ( >= v0.16.0) )
50
50
( lsp ( = :version ) )
51
51
( jsonrpc ( = :version ) )
@@ -75,8 +75,9 @@ possible and does not make any assumptions about IO.
75
75
76
76
( package
77
77
(name jsonrpc)
78
- (synopsis " Jsonrpc protocol implemenation " )
78
+ (synopsis " Jsonrpc protocol implementation " )
79
79
( description " See https://www.jsonrpc.org/specification" )
80
80
( depends
81
+ yojson
81
82
( ocaml ( >= 4 .08) )
82
83
( odoc :with -doc) ) )
Original file line number Diff line number Diff line change 1
1
# This file is generated by dune, edit dune-project instead
2
2
opam-version: "2.0"
3
- synopsis: "Jsonrpc protocol implemenation "
3
+ synopsis: "Jsonrpc protocol implementation "
4
4
description: "See https://www.jsonrpc.org/specification"
5
5
maintainer: ["Rudi Grinberg <
[email protected] >"]
6
6
authors: [
@@ -20,6 +20,7 @@ homepage: "https://github.com/ocaml/ocaml-lsp"
20
20
bug-reports: "https://github.com/ocaml/ocaml-lsp/issues"
21
21
depends: [
22
22
"dune" {>= "3.0"}
23
+ "yojson"
23
24
"ocaml" {>= "4.08"}
24
25
"odoc" {with-doc}
25
26
]
Original file line number Diff line number Diff line change 1
1
(library
2
2
(public_name jsonrpc)
3
+ (libraries yojson)
3
4
(instrumentation
4
5
(backend bisect_ppx)))
Original file line number Diff line number Diff line change @@ -9,18 +9,7 @@ module Option = struct
9
9
end
10
10
11
11
module Json = struct
12
- type t =
13
- [ `Assoc of (string * t ) list
14
- | `Bool of bool
15
- | `Float of float
16
- | `Int of int
17
- | `Intlit of string
18
- | `List of t list
19
- | `Null
20
- | `String of string
21
- | `Tuple of t list
22
- | `Variant of string * t option
23
- ]
12
+ type t = Yojson.Safe .t
24
13
25
14
exception Of_json of (string * t)
26
15
Original file line number Diff line number Diff line change 1
1
(* * Jsonrpc implementation *)
2
2
3
3
module Json : sig
4
- type t =
5
- [ `Assoc of (string * t ) list
6
- | `Bool of bool
7
- | `Float of float
8
- | `Int of int
9
- | `Intlit of string
10
- | `List of t list
11
- | `Null
12
- | `String of string
13
- | `Tuple of t list
14
- | `Variant of string * t option
15
- ]
4
+ type t = Yojson.Safe .t
16
5
17
6
(* * Raised when conversions from json fail *)
18
7
exception Of_json of (string * t)
Original file line number Diff line number Diff line change @@ -64,11 +64,11 @@ module Json = struct
64
64
| `Bool f -> Bool f
65
65
| `Assoc o -> Record (List. map o ~f: (fun (k , v ) -> k, to_dyn v))
66
66
| `List l -> List (List. map l ~f: to_dyn)
67
- | `Tuple args -> Tuple (List. map args ~f: to_dyn)
68
67
| `Null -> Dyn. Variant (" Null" , [] )
69
- | `Variant (name , Some arg ) -> Variant (name, [ to_dyn arg ])
70
- | `Variant (name , None) -> Variant (name, [] )
71
68
| `Intlit s -> String s
69
+ | _ -> Dyn. Variant (" Unsupported" , [] )
70
+ (* This last case is unused with Yojson >= 3 *)
71
+ [@@ warning " -11" ]
72
72
;;
73
73
end
74
74
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ bug-reports: "https://github.com/ocaml/ocaml-lsp/issues"
25
25
depends: [
26
26
"dune" {>= "3.0"}
27
27
"jsonrpc" {= version}
28
- "yojson" {< "3.0.0"}
28
+ "yojson"
29
29
"ppx_yojson_conv_lib" {>= "v0.14"}
30
30
"cinaps" {with-test}
31
31
"ppx_expect" {>= "v0.17.0" & with-test}
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ homepage: "https://github.com/ocaml/ocaml-lsp"
20
20
bug-reports: "https://github.com/ocaml/ocaml-lsp/issues"
21
21
depends: [
22
22
"dune" {>= "3.0"}
23
- "yojson" {< "3.0.0"}
23
+ "yojson"
24
24
"base" {>= "v0.16.0"}
25
25
"lsp" {= version}
26
26
"jsonrpc" {= version}
You can’t perform that action at this time.
0 commit comments