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

Implement P2652R2 Disallowing User Specialization Of allocator_traits #3542

Merged
merged 6 commits into from
Mar 7, 2023

Conversation

frederick-vs-ja
Copy link
Contributor

@frederick-vs-ja frederick-vs-ja commented Mar 6, 2023

Fixes #3443. Also enables support and test coverage for EDG.

Upgrades allocator_traits::allocate_at_least to _NODISCARD_RAW_PTR_ALLOC.

I've filed DevCom-10301073 to request compiler support for this. Given compilers are already required to reject initializer_list specialization declarations, I think it's reasonable to do the same thing for allocator_traits.

Also enable EDG support and test coverage
@frederick-vs-ja frederick-vs-ja requested a review from a team as a code owner March 6, 2023 16:40
@StephanTLavavej StephanTLavavej added the cxx23 C++23 feature label Mar 6, 2023
stl/inc/xmemory Outdated Show resolved Hide resolved
stl/inc/xmemory Outdated Show resolved Hide resolved
stl/inc/xmemory Outdated Show resolved Hide resolved
stl/inc/xmemory Outdated Show resolved Hide resolved
@StephanTLavavej
Copy link
Member

Thanks! 😻 I've pushed very minor changes, including a tiny throughput improvement. FYI @strega-nil-ms as you already approved.

@StephanTLavavej StephanTLavavej self-assigned this Mar 7, 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 daa994b into microsoft:main Mar 7, 2023
@StephanTLavavej
Copy link
Member

Thanks again for updating allocate_at_least()'s machinery, improving its nodiscard diagnostic, and requesting compiler support to keep bad kitties from jumping up on the table where they're not allowed! ⚙️ 🐈 😻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cxx23 C++23 feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

P2652R2 Disallowing User Specialization Of allocator_traits
3 participants