-
Notifications
You must be signed in to change notification settings - Fork 118
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
Optional arguments supplied with ~ are completed with ? instead #1179
Comments
Or we could offer completions for |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When requesting completion for a function's optional labeled argument, which the user intends to pass with
~
, OCaml-LSP's completion suggestion uses?
instead and replaces the original intended meaning, e.g.:If, at the end of that snippet, the user presses TAB (or whatever completion key), OCaml-LSP suggests:
as some of the completion results. Selecting
?abc
causes the code to now look like:whereas the expected behavior is more likely:
This issue also occurs if the user has typed some prefix of the optional argument label first.
Here's the event log item I got from Emacs:
I think maybe the label should remain
?abc
but thenewText
should be~abc
instead?The text was updated successfully, but these errors were encountered: