754fca77e8
Removing the allocator<void> specialization for the versioned namespace breaks _Extptr_allocator<void> because the allocator<void> specialization was still declared in <bits/memoryfwd.h>, making it an incomplete type. It wrong to remove that specialization anyway, because it is still needed pre-C++20. This removes the #if ! _GLIBCXX_INLINE_VERSION check, so that allocator<void> is still explicitly specialized for the versioned namespace, consistent with the normal unversioned namespace mode. To make _Extptr_allocator<void> usable as a ProtoAllocator, this change adds a default constructor and converting constructor. That is consistent with std::allocator<void> since C++20 (and harmless to do for earlier standards). I'm also explicitly specializing allocator_traits<allocator<void>> so that it doesn't need to use allocator<void>::construct and destroy. Doing that allows those members to be removed, further simplifying allocator<void>. That new explicit specialization can delete the allocate, deallocate and max_size members, which are always ill-formed for allocator<void>. Signed-off-by: Jonathan Wakely <jwakely@redhat.com> libstdc++-v3/ChangeLog: * include/bits/alloc_traits.h (allocator_traits): Add explicit specialization for allocator<void>. Improve doxygen comments. * include/bits/allocator.h (allocator<void>): Restore for the versioned namespace. (allocator<void>::construct, allocator<void>::destroy): Remove. * include/ext/extptr_allocator.h (_Extptr_allocator<void>): Add default constructor and converting constructor. |
||
---|---|---|
.. | ||
config | ||
doc | ||
include | ||
libsupc++ | ||
po | ||
python | ||
scripts | ||
src | ||
testsuite | ||
acinclude.m4 | ||
aclocal.m4 | ||
ChangeLog | ||
ChangeLog-1998 | ||
ChangeLog-1999 | ||
ChangeLog-2000 | ||
ChangeLog-2001 | ||
ChangeLog-2002 | ||
ChangeLog-2003 | ||
ChangeLog-2004 | ||
ChangeLog-2005 | ||
ChangeLog-2006 | ||
ChangeLog-2007 | ||
ChangeLog-2008 | ||
ChangeLog-2009 | ||
ChangeLog-2010 | ||
ChangeLog-2011 | ||
ChangeLog-2012 | ||
ChangeLog-2013 | ||
ChangeLog-2014 | ||
ChangeLog-2015 | ||
ChangeLog-2016 | ||
ChangeLog-2017 | ||
ChangeLog-2018 | ||
ChangeLog-2019 | ||
ChangeLog-2020 | ||
config.h.in | ||
configure | ||
configure.ac | ||
configure.host | ||
crossconfig.m4 | ||
fragment.am | ||
linkage.m4 | ||
Makefile.am | ||
Makefile.in | ||
README |
file: libstdc++-v3/README New users may wish to point their web browsers to the file index.html in the 'doc/html' subdirectory. It contains brief building instructions and notes on how to configure the library in interesting ways.