Proper generic way to get the hash of something?

Tofu Ninja via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Dec 3 22:51:24 PST 2016


What is the proper generic way to get the hash of something? It 
seems that hashOf has been changed to no longer call toHash on 
anything.... Just blindly casts to void[]. It actually seems now 
toHash doesn't call any of the specializations of 
core.internal.hash.hashOf except the one for void[]. The change 
seems pretty dumb and broke my code, not sure why it was done, 
the breakage is not in the change log :/.

So what is the proper way to get the hash of something now?


More information about the Digitalmars-d-learn mailing list