Open
Conversation
Signed-off-by: Nicolas Ojeda Bar <n.oje.bar@gmail.com>
Signed-off-by: Nicolas Ojeda Bar <n.oje.bar@gmail.com>
Member
|
At first glance, this seems like a rather niche feature that's not going to be beneficial to many users. On the other hand, it does seem like there's something missing here in dune. Is it so difficult to keep this patch in your fork while we're still thinking of a way to generalize this feature? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR (which arose from a local patch that we have at LexiFi) adds a new field to the
(library)stanza:(excluded_modules). This field (which is similar to(private_modules)) specifies a list of modules that:In our setting inside LexiFi, we define a library which contains the main part of our application code where the exact list of modules can vary from client to client, so we generate the list of modules dynamically using
(:include). However, we want to make sure that the rest of the modules (which are not "active" for the current client) continue to compile. This feature is useful whenever you have "inactive" modules that you wish to make sure they still compile.This feature can be simulated by introducing a second library, but doing so incurs in a substantial penalty due to the unnecessary recompilations caused by Dune's coarse-grained inter-library dependency approximation, as well as extra linking steps which can be quite slow.
Doc and tests are included.