Repository navigation
Fix dictifyCPPDEFINES handling of macro strings - #4329
Merged
Merged
Conversation
CPPDEFINES can contain name=value strings, either a single one, or one or more in a sequence type. After conversion (subsequent Append/Prepend to CPPDEFINES), these will be stored as tuples, but it is possible to hit cases where the type conversion has never been triggered. The C Scanner has its own routine to process CPPDEFINES, and missed these cases, which are now handled. The testcases in issue 4193 which showed this problem are now included in the C scanner unit tests, and the test for dictifyCPPDEFINES is expanded to check these two forms. Fixes SCons#4193 Signed-off-by: Mats Wichmann <[email protected]>
* Single-tuple CPPDEFINES was not handled. * Add some more unit tests. * Add some comments - that we need to keep in sync with processDefines, but don't actually call it (the routine *could* be rewritten to process the result of processDefines instead of the bare CPPDEFINES, but currently doesn't do that). Signed-off-by: Mats Wichmann <[email protected]>
bdbaddog
reviewed
Mar 26, 2023
|
|
||
| - Whatever John Doe did. | ||
| From Mats Wichmann | ||
| - C scanner's dictifyCPPDEFINES routine did not understand the possible |
Contributor
There was a problem hiding this comment.
Please add a blurb to RELEASE.txt as well.
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.
CPPDEFINEScan containname=valuestrings, either a single one, or one or more in a sequence type. After conversion (subsequent Append/Prepend toCPPDEFINES), these will be stored as tuples, but it is possible to hit cases where the type conversion has never been triggered. The C Scanner has its own routine to processCPPDEFINES, and missed these cases, which are now handled.The testcases in issue 4193 which showed this problem are now included in the C scanner unit tests, and the test for
dictifyCPPDEFINESis expanded to check these two forms.Fixes #4193
Contributor Checklist:
CHANGES.txt(and read theREADME.rst)