[libcxx-commits] [PATCH] D104398: [libc++] Make sure std::allocator<void> is always trivial
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Jun 16 10:08:26 PDT 2021
ldionne created this revision.
ldionne added a reviewer: Quuxplusone.
ldionne requested review of this revision.
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++.
When we removed the allocator<void> specialization, the triviality of
std::allocator<void> changed because the primary template had a
non-trivial default constructor and the specialization didn't
(so std::allocator<void> went from trivial to non-trivial).
This commit fixes that oversight by giving a trivial constructor to
the primary template when instantiated on cv-void.
This was reported in https://llvm.org/PR50299.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D104398
Files:
libcxx/include/__memory/allocator.h
libcxx/test/libcxx/memory/allocator_void.trivial.compile.pass.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D104398.352472.patch
Type: text/x-patch
Size: 4040 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20210616/ee40a4d2/attachment-0001.bin>
More information about the libcxx-commits
mailing list