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.
Internal discussion raised the question of how compatible zstd's headers are with C++ Modules, given that we use configuration macros to control what is exposed by
zstd.h
. This is a valid topic that is probably worth further discussion. It may be that the right approach is to expose a secondlibzstd-static
module that exports the static definitions.For the time being though, this PR makes several changes that seem worthwhile:
module.modulemap
file into the root of the lib directory. Experimentation shows that clang's-fimplicit-module-maps
will find the module map when placed here, but not when it's put in a subdirectory.I know the module map was initially added in #2858. I don't have the capability to test whether these changes are compatible. Ideally @cntrump could weigh in.
To-do: create tests that can be added to validate that zstd remains compatible with modules. This is complicated by the fact that support is still experimental and present in only the most recent compilers.