From: Albert Wagner Date: 2002-02-17T04:27:46+09:00 Subject: Re: hash as key in hash On Saturday 16 February 2002 01:11 pm, you wrote: > After going through all this, you might want to extend the Hash class > and override hash() with these calls: > > class HashWhichYouCanReliablyUseAsKeyInAHash < Hash > def hash > return sort.to_s > end > end > > And create your hash indexes by creating new instances of the new class. Thanks, Thomas. I was aware that the hashes for equal-content hashes were different, I just thought that it was wrong for that to be true. Your last option, above, is what I'll try. I was afraid to override the hash method, not knowing why it used the ID. -- Quantum Mechanics: The dreams stuff is made of