[all-commits] [llvm/llvm-project] 87784c: [libc++] Undeprecate the std::allocator<void> spec...
Louis Dionne via All-commits
all-commits at lists.llvm.org
Wed Jun 16 06:55:07 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 87784cc6fb3453a17e0e7826b943a1d93cbfeccf
https://github.com/llvm/llvm-project/commit/87784cc6fb3453a17e0e7826b943a1d93cbfeccf
Author: Louis Dionne <ldionne.2 at gmail.com>
Date: 2021-06-16 (Wed, 16 Jun 2021)
Changed paths:
M libcxx/docs/UsingLibcxx.rst
M libcxx/include/__memory/allocator.h
M libcxx/include/memory
M libcxx/test/libcxx/depr/depr.default.allocator/allocator_types.cxx2a.pass.cpp
R libcxx/test/libcxx/depr/depr.default.allocator/allocator_void.cxx2a.pass.cpp
A libcxx/test/std/utilities/memory/default.allocator/PR50299.compile.pass.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator.ctor.pass.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator.dtor.pass.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator_pointers.pass.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator_types.deprecated_in_cxx17.verify.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator_types.pass.cpp
M libcxx/test/std/utilities/memory/default.allocator/allocator_types.removed_in_cxx20.verify.cpp
A libcxx/test/std/utilities/memory/default.allocator/allocator_types.void.compile.pass.cpp
R libcxx/test/std/utilities/memory/default.allocator/allocator_void.deprecated_in_cxx17.verify.cpp
Log Message:
-----------
[libc++] Undeprecate the std::allocator<void> specialization
While the std::allocator<void> specialization was deprecated by
https://wg21.link/p0174#2.2, the *use* of std::allocator<void> by users
was not. The intent was that std::allocator<void> could still be used
in C++17 and C++20, but starting with C++20 (with the removal of the
specialization), std::allocator<void> would use the primary template.
That intent was called out in wg21.link/p0619r4#3.9.
As a result of this patch, _LIBCPP_ENABLE_CXX20_REMOVED_ALLOCATOR_MEMBERS
will also not control whether the explicit specialization is provided or
not. It shouldn't matter, since in C++20, one can simply use the primary
template.
Fixes http://llvm.org/PR50299
Differential Revision: https://reviews.llvm.org/D104323
More information about the All-commits
mailing list