From 216605be9c076a5bba87dc4e77161e7d0d5ad466 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Loi=CC=88c=20Correnson?= <loic.correnson@cea.fr>
Date: Mon, 11 Mar 2019 11:11:26 +0100
Subject: [PATCH] [server] avoid deprecated Basic.json

---
 src/plugins/server/data.ml     | 2 +-
 src/plugins/server/doc.ml      | 4 ++--
 src/plugins/server/jbuffer.ml  | 2 +-
 src/plugins/server/jbuffer.mli | 2 +-
 src/plugins/server/main.ml     | 2 +-
 src/plugins/server/main.mli    | 2 +-
 6 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/src/plugins/server/data.ml b/src/plugins/server/data.ml
index f40abf8eb99..10a7eef4774 100644
--- a/src/plugins/server/data.ml
+++ b/src/plugins/server/data.ml
@@ -27,7 +27,7 @@
 module Json = Yojson.Basic
 module Jutil = Yojson.Basic.Util
 
-type json = Json.json
+type json = Json.t
 let pretty = Json.pretty_print ~std:false
 
 module type S =
diff --git a/src/plugins/server/doc.ml b/src/plugins/server/doc.ml
index f68815c2cfa..9b4eabf3a5e 100644
--- a/src/plugins/server/doc.ml
+++ b/src/plugins/server/doc.ml
@@ -125,7 +125,7 @@ let index () =
     (fun (title,entry) -> Markdown.href ~title entry)
     (List.sort (fun (a,_) (b,_) -> String.compare a b) !entries)
 
-type json = Yojson.Basic.json
+type json = Json.t
 
 let link ~toc ~title ~href : json =
   let link = [ "title" , `String title ; "href" , `String href ] in
@@ -141,7 +141,7 @@ let link_page page : json list =
        else links
     ) (pages_of_chapter page.chapter) []
 
-let maindata : Yojson.Basic.json =
+let maindata : json =
   `Assoc [
     "document", `String "Frama-C Server" ;
     "title",`String "Documentation" ;
diff --git a/src/plugins/server/jbuffer.ml b/src/plugins/server/jbuffer.ml
index 3fe46fd62db..2f9e3bfa57b 100644
--- a/src/plugins/server/jbuffer.ml
+++ b/src/plugins/server/jbuffer.ml
@@ -20,7 +20,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-type json = Yojson.Basic.json
+type json = Json.t
 
 type buffer = {
   text : FCBuffer.t ;
diff --git a/src/plugins/server/jbuffer.mli b/src/plugins/server/jbuffer.mli
index d384e4352e8..6f307acf2d1 100644
--- a/src/plugins/server/jbuffer.mli
+++ b/src/plugins/server/jbuffer.mli
@@ -20,7 +20,7 @@
 (*                                                                        *)
 (**************************************************************************)
 
-type json = Yojson.Basic.json
+type json = Json.t
 
 (** All-in-one formatter. Return the JSON encoding of formatted text. *)
 val format : ?indent:int -> ?margin:int ->
diff --git a/src/plugins/server/main.ml b/src/plugins/server/main.ml
index 9edee0df225..28491bb2949 100644
--- a/src/plugins/server/main.ml
+++ b/src/plugins/server/main.ml
@@ -55,7 +55,7 @@ let exec request data = (snd (Hashtbl.find registry request)) data
 (* --- Public API                                                         --- *)
 (* -------------------------------------------------------------------------- *)
 
-type json = Json.json
+type json = Json.t
 
 type 'a request = [
   | `Poll
diff --git a/src/plugins/server/main.mli b/src/plugins/server/main.mli
index b608cdafa76..b379f14bd2a 100644
--- a/src/plugins/server/main.mli
+++ b/src/plugins/server/main.mli
@@ -24,7 +24,7 @@
 (** Server Main Process *)
 (* -------------------------------------------------------------------------- *)
 
-type json = Yojson.Basic.json
+type json = Json.t
 type kind = [ `GET | `SET | `EXEC ]
 val string_of_kind : kind -> string
 val pp_kind : Format.formatter -> kind -> unit
-- 
GitLab