std::collate hash() still broken

Paolo Carlini pcarlini@unitus.it
Sun Feb 10 03:38:00 GMT 2002


AWLaFramboise@aol.com wrote:

> hi
>
> i noticed in gcc3.0.3 std::collate hash() was broken, so i checked cvs. the obvious bug had been fixed, but still leaving a more subtle one.  its a rotary hash.. it should be doing a full rotate instead of a fonky kindof rotate like it is now.  the thing it has right now will not work correctly.  try comparing hashes of "xxxx" to "xxxxxxxx" or something.. they're identical.

Probably you are right, but I have trouble reproducing the problem you are mentioning.

paolo:~> a.out
String: xxxx
Hash: 0xf1e3c78
paolo:~> a.out
String: xxxxxxxx
Hash: 0x8f1e7cf9

Could you possibly explain it in some more detail?

Thanks,
Paolo.




More information about the Libstdc++ mailing list