hash function

H. S. Teoh hsteoh at quickfur.ath.cx
Fri Feb 15 07:13:24 PST 2013


On Fri, Feb 15, 2013 at 08:28:34AM +0100, Jacob Carlborg wrote:
> On 2013-02-15 03:26, Adam D. Ruppe wrote:
> >druntime has a hash implementation in module rt.util.hash that looks
> >pretty useful, but isn't publicaly exported by the library anywhere.
> >
> >Does phobos or druntime offer a public hash function like that? If no,
> >can it expose this one?
> 
> TypeInfo has a "getHash" method.
[...]

Which has a lot of bugs and inconsistencies. Like the fact that hashing
a char[], a const(char)[], and a string (immutable(char)[]) gives
different results.


T

-- 
Blunt statements really don't have a point.


More information about the Digitalmars-d mailing list