[PATCH] PR libstdc++/90388 fix std::hash<unique_ptr<T,D>> bugs

Ville Voutilainen ville.voutilainen@gmail.com
Fri May 10 21:51:00 GMT 2019


On Sat, 11 May 2019 at 00:42, Jonathan Wakely <jwakely@redhat.com> wrote:
>
> A disabled specialization should not be callable, so move the function
> call operator into a new base class which correctly implements the
> disabled hash semantics. For the versioned namespace configuration do
> not derive from __poison_hash in the enabled case, as the empty base
> class serves no purpose but potentially increases the object size. For
> the default configuration that base class must be kept, to preserve
> layout.

I continue to not be a fan of the versioned namespace ifdeffery in
this, but I can live with it.



More information about the Libstdc++ mailing list