Pass compilation context via swift info in hmap creation due to rules_swift 2.1.1 #906
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.
One of the CI error is:
This is because this header was suppose to be an input to Swift compile via hmap creation rule. But in this breaking change bazelbuild/rules_swift@d68b214 rules_swift stopped collecting compilation context from
CcInfo
if the target is Swift code (line 1555 ofswift/internal/compiling.bzl
). Instead it depends on reading the same info fromclang_module.compilation_context
which is available fromSwiftInfo
provider (SwiftInfo -> modules -> clang)This PR deals with header maps side where we propagate compilation context via this
clang
moduleNext step is to do the same for other places where we need to pass the compilation context
CI for this PR should no longer produce this error (but will still fail on some other tests)