SCons: Pass /Zc:__cplusplus
in MSVC builds
#96244
Merged
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.
Passing this C++ flag on MSVC will allow
__cplusplus
to function like it does on every sensible compiler: specifying the C++ Standard used. While a largely superfluous addition when we're locked to C++17 atm, I wanted to separate this from the C++20 PR because this macro could have potential ramifications on its own. Based off local testing, that doesn't seem to be the case, but I wanted to ensure this change was in as controlled of an environment as possible.