mirror of
https://github.com/c-cube/linol.git
synced 2026-05-05 08:54:26 -04:00
format
This commit is contained in:
parent
2e7a8f3482
commit
266b911bb3
2 changed files with 6 additions and 7 deletions
|
|
@ -37,7 +37,7 @@ let diagnostics (_state : state_after_processing) : Lsp.Types.Diagnostic.t list
|
||||||
so that users only need to override methods that they want the server to
|
so that users only need to override methods that they want the server to
|
||||||
actually meaningfully interpret and respond to.
|
actually meaningfully interpret and respond to.
|
||||||
*)
|
*)
|
||||||
class lsp_server ~(sw: Eio.Switch.t) =
|
class lsp_server ~(sw : Eio.Switch.t) =
|
||||||
object (self)
|
object (self)
|
||||||
inherit Linol_eio.Jsonrpc2.server
|
inherit Linol_eio.Jsonrpc2.server
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -54,12 +54,11 @@ end
|
||||||
(** Spawn function. *)
|
(** Spawn function. *)
|
||||||
let spawn ~sw f =
|
let spawn ~sw f =
|
||||||
Eio.Fiber.fork ~sw (fun () ->
|
Eio.Fiber.fork ~sw (fun () ->
|
||||||
try
|
try f ()
|
||||||
f ()
|
with exn ->
|
||||||
with exn ->
|
Printf.eprintf "uncaught exception in `spawn`:\n%s\n%!"
|
||||||
Printf.eprintf "uncaught exception in `spawn`:\n%s\n%!"
|
(Printexc.to_string exn);
|
||||||
(Printexc.to_string exn);
|
raise exn)
|
||||||
raise exn)
|
|
||||||
|
|
||||||
include Lsp.Types
|
include Lsp.Types
|
||||||
include IO_eio
|
include IO_eio
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue