-
Notifications
You must be signed in to change notification settings - Fork 131
Draft: Delegate outline generation to Merlin #1529
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What a nice PR! Thanks!
"end": { "character": 10, "line": 2 }, | ||
"start": { "character": 9, "line": 2 } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sometime the result spans multiple lines like the previous one for a
. But sometimes the only highlight the character like this one for b
. Do you know why ?
I expect for most editors this is not an issue since they only use the start position ? But we might want to be a bit more careful about what we return here...
I guess that the PR can be |
Pull Request Test Coverage Report for Build 4862Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
Replacement of the in-house solution for generating outlines by Merlin.
I had to regenerate the tests because merlin and ocaml-lsp don't calculate the positions of elements in the outline in the same way. Fir instance, the
y
loc was the enclosing location for ocaml-lsp:While Merlin indicates the exact position:
The PR diff also indicates that several items
kind
value have changed from 7 to 13. Indeed, Merlin treats instance variables asValues
and not asProperty
like ocaml-lsp does. This change simply means that the icon displayed on the vscode side will be differentCould you please mark this PR has draft? We have to wait for the next Merlin next because we need this patch ocaml/merlin#1936