Teach cc_args to interop with BuildSettingInfo#599
Open
dzbarsky wants to merge 2 commits intobazelbuild:mainfrom
Open
Teach cc_args to interop with BuildSettingInfo#599dzbarsky wants to merge 2 commits intobazelbuild:mainfrom
dzbarsky wants to merge 2 commits intobazelbuild:mainfrom
Conversation
18b2481 to
483be8b
Compare
fmeum
approved these changes
Feb 8, 2026
483be8b to
bceda87
Compare
bceda87 to
640cf52
Compare
trybka
requested changes
Feb 9, 2026
cc/toolchains/impl/nested_args.bzl
Outdated
| if VariableInfo in target: | ||
| return "%%{%s}" % target[VariableInfo].name | ||
| elif BuildSettingInfo in target: | ||
| return _format_build_setting(target, fail = fail) |
Collaborator
There was a problem hiding this comment.
nit: consistency-wise it seems odd that we pass in target[Provider].field above and below (in escape), but just pass in target here. Maybe for consistency sake pass in target[BuildSettingInfo].value here and then omit the first line of the function?
| ) | ||
| c_compile.files().contains_at_least(_SIMPLE_FILES) | ||
|
|
||
| def _build_setting_format_test(env, targets): |
Collaborator
There was a problem hiding this comment.
can you add a test that sets the flag to a new value and validates that the new value is used?
Contributor
Author
|
@trybka feedback addressed, PTAL! |
d28d71c to
d3dfcff
Compare
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.
No description provided.