Skip to content

Commit

Permalink
Specify -index 0 in type-enclosing queries.
Browse files Browse the repository at this point in the history
This change might greatly improve performances in some cases where Merlin would format big types that were discarded by ocaml-lsp anyway.
  • Loading branch information
voodoos committed Sep 26, 2023
1 parent 26b52dd commit 5f5e1f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ocaml-lsp-server/src/document.ml
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ module Merlin = struct

let type_enclosing doc pos verbosity =
with_pipeline_exn doc (fun pipeline ->
let command = Query_protocol.Type_enclosing (None, pos, None) in
let command = Query_protocol.Type_enclosing (None, pos, Some 0) in
let pipeline =
match verbosity with
| 0 -> pipeline
Expand Down

0 comments on commit 5f5e1f2

Please sign in to comment.