On Fri, 27 Aug 2021 at 22:17, Jonathan Wakely <jwak...@redhat.com> wrote: > > On Fri, 27 Aug 2021 at 21:58, François Dumont via Libstdc++ > <libstd...@gcc.gnu.org> wrote: > > > > Since std::allocator<void> is not specialized anymore in > > _GLIBCXX_INLINE_VERSION mode _ExtPtr_allocator<void> specialization do > > not compile > > > > because std::allocator<void> is incomplete. > > That doesn't look right ... it should be complete. This suggests there > is a deeper problem, which I'll look into.
This is the correct fix: --- a/libstdc++-v3/include/bits/memoryfwd.h +++ b/libstdc++-v3/include/bits/memoryfwd.h @@ -63,8 +63,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION template<typename> class allocator; +#if ! _GLIBCXX_INLINE_VERSION template<> class allocator<void>; +#endif #if __cplusplus >= 201103L /// Declare uses_allocator so it can be specialized in `<queue>` etc. > > > > > > So I think primary _ExtPtr_allocator template should also be prefered in > > _GLIBCXX_INLINE_VERSION mode. > > I think it should always be preferred. The _ExtPtr_allocator<void> > specialization is useless, it is missing the converting constructor > that would be needed to convert to/from that type to any other > _ExtPtr_allocator<T> specialization.