Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move some components from upstream headers to downstream #3719

Merged
merged 5 commits into from
May 30, 2023

Conversation

frederick-vs-ja
Copy link
Contributor

@frederick-vs-ja frederick-vs-ja commented May 19, 2023

  1. Move _MAX_* macros from <yvals.h> to <xlocnum> so that they can be #undef'd in the same header. Also demacroize _MAX_INT_DIG and rename it to _Max_int_dig, because it is used in multiple headers.
  2. Move integer_sequence and its friends from <type_traits> to <utility> where the standard provides them.
  3. Move allocator_arg, uses_allocator and their friends from <utility> to <__msvc_iter_core.hpp> where suitable. Although they are unrelated to iterators.

So that they can be `#undef`'d in the same header.

Also demacroize `_MAX_INT_DIG` and rename it to `_Max_int_dig`, because
it is used in multiple headers.
where the standard provides it, together with its friends.
from `<utility>` to `<__msvc_iter_core.hpp>` where suitable. Although
they are unrelated to iterators.
@frederick-vs-ja frederick-vs-ja requested a review from a team as a code owner May 19, 2023 17:35
@CaseyCarter CaseyCarter added the enhancement Something can be improved label May 19, 2023
Copy link
Member

@CaseyCarter CaseyCarter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a couple of pre-existing comment nitpicks that I'll go ahead and apply. Thanks, this is a nice cleanup.

stl/inc/__msvc_iter_core.hpp Outdated Show resolved Hide resolved
stl/inc/__msvc_iter_core.hpp Outdated Show resolved Hide resolved
Just a couple of pre-existing comment nits.
@StephanTLavavej StephanTLavavej self-assigned this May 24, 2023
@StephanTLavavej StephanTLavavej removed their assignment May 25, 2023
@StephanTLavavej StephanTLavavej self-assigned this May 26, 2023
@StephanTLavavej
Copy link
Member

I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed.

@StephanTLavavej StephanTLavavej merged commit a4bb668 into microsoft:main May 30, 2023
@StephanTLavavej
Copy link
Member

Thanks for improving our header structure and very slightly increasing throughput for rare TUs! 🎉 ✨ 😺

@StephanTLavavej StephanTLavavej added throughput Must compile faster and removed enhancement Something can be improved labels May 30, 2023
@frederick-vs-ja frederick-vs-ja deleted the small-code-moves branch May 30, 2023 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
throughput Must compile faster
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants