Problem with _Hashtable_ebo_helper
François Dumont
frs.dumont@gmail.com
Tue Oct 22 20:59:00 GMT 2013
On 10/21/2013 10:39 PM, Jason Merrill wrote:
> I've been working on fixing G++ handling of trivial but not callable
> [cd]tors, and I've run into a problem in the library.
>
> The final_hash.cc tests are failing with the obscure error
>
>> error: static assertion failed: Cache the hash code or make functors
>> involved in hash code and bucket index computation default constructible
>
> A comment in hashtable.h says,
>
>> // We use _Hashtable_ebo_helper to access the protected
>> // default constructor.
>
> But this doesn't work if the class with a protected default
> constructor (in this case, _Hash_code_base) is non-empty; in that
> case, _Hashtable_ebo_helper doesn't derive from _Tp but rather uses it
> as a non-static data member, in which case it has no access to the
> protected constructor. Previously the compiler didn't catch this
> because the constructor was trivial, but with my WIP it does.
>
> Any thoughts about how to address this?
>
> Jason
> .
>
I will have a look.
François
More information about the Libstdc++
mailing list