ocaml-lsp icon indicating copy to clipboard operation
ocaml-lsp copied to clipboard

Cannot disable short-paths

Open Sakarah opened this issue 11 months ago • 3 comments

As stated in issue #1227, short-paths usually gives weird behaviors for code using type aliases.

In the OCaml compiler, this issue can sometimes be mitigated by not using the -short-paths option to force displaying full paths in error messages. Such types are usually longer but at least they are similar to the declared function signature.

With OCaml LSP, such a mitigation seems inaccessible with the current implementation. The -short-path option is always enabled by default. If I understand correctly, passing the real_path option to the underlying Merlin should disable this path shortening and give a behavior that is similar to the compiler without the -short-paths option.

Ideally, I would like to be able to use OCaml LSP with Merlin in real_paths mode for some projects, and in the current short_paths mode for others.

Sakarah avatar Nov 15 '24 14:11 Sakarah