merlin
merlin copied to clipboard
document doesn't work reliably in source files
For example, it doesn't work when the expression after a toplevel let is on its own line:
% cat test.ml
let foo =
()
(** COMMENT *)
let () = foo
% cat test.ml | ocamlmerlin single document -position 5:11
{"class":"return","value":"No documentation available","notifications":[],"timing":{"clock":1,"cpu":1,"query":0,"pp":0,"reader":0,"ppx":0,"typer":1,"error":0}}
While this works as expected:
% cat test.ml
let foo = ()
(** COMMENT *)
let () = foo
% cat test.ml | ocamlmerlin single document -position 5:11
{"class":"return","value":"COMMENT","notifications":[],"timing":{"clock":1,"cpu":1,"query":0,"pp":0,"reader":0,"ppx":0,"typer":1,"error":0}}