Skip to content
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

fix: merlin and private_modules #6405

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

rgrinberg
Copy link
Member

When private modules are enabled, only the public cmi directory was
passed to merlin. The end result is that all .cmt and .cmti files were
hidden causing a degraded experience. We fix this by providing the
private dir to merlin.

Signed-off-by: Rudi Grinberg [email protected]

ps-id: dc5a051b-ca65-48cf-a63f-8a61128b2cf2

When private modules are enabled, only the public cmi directory was
passed to merlin. The end result is that all .cmt and .cmti files were
hidden causing a degraded experience. We fix this by providing the
private dir to merlin.

Signed-off-by: Rudi Grinberg <[email protected]>

ps-id: dc5a051b-ca65-48cf-a63f-8a61128b2cf2
@rgrinberg rgrinberg requested a review from voodoos November 8, 2022 03:47
@rgrinberg rgrinberg added this to the 3.6.0 milestone Nov 8, 2022
@voodoos
Copy link
Collaborator

voodoos commented Nov 8, 2022

Won't doing this "desynchronize" Merlin and the compiler ? If Merlin has access to the cmis of the private modules it will suggest private values during autocompletion and not report errors when using them.

@rgrinberg rgrinberg modified the milestones: 3.6.0, 3.7.0 Nov 8, 2022
@rgrinberg
Copy link
Member Author

Ah that's annoying. I guess we'll need to copy the .cmt and .cmtis to a separate folder after all.

Removed the 3.6.0 milestone as this is a bit harder.

@emillon
Copy link
Collaborator

emillon commented Jan 30, 2023

@rgrinberg do you have a fix for 3.7 or should we clear the milestone?

@rgrinberg rgrinberg modified the milestones: 3.7.0, 3.8.0 Feb 1, 2023
@rgrinberg rgrinberg marked this pull request as draft February 28, 2023 18:31
@emillon
Copy link
Collaborator

emillon commented Apr 19, 2023

I'll clear the milestone this is is unlikely to get in 3.8.

@emillon emillon removed this from the 3.8.0 milestone Apr 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Private modules cause missing build path (in the ocaml-merlin dump)
3 participants