https://issues.dlang.org/show_bug.cgi?id=16654
Issue ID: 16654 Summary: hashOf returns different hashes for the same string value Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: major Priority: P1 Component: druntime Assignee: nob...@puremagic.com Reporter: d...@nomad.so The following assert fails: import std.stdio; import std.conv; void main(string[] args) { auto x = 1; assert(hashOf(x.to!(string)) == hashOf(x.to!(string))); } This is because numeric values of the pointers to the strings are being included in the hash calculation. Discussion: http://forum.dlang.org/post/gdtaqdooaknhsmcow...@forum.dlang.org --