From: Bertram Scharpf Date: 2005-01-27T22:46:04+09:00 Subject: Re: Array::uniq { block } ? Hi, Am Donnerstag, 27. Jan 2005, 20:11:35 +0900 schrieb ts: > >>>>> "R" == Robert Klemme writes: > > R> I don't see eql? called here - maybe it's an internal optimization that > R> short circuits identity. Or did I miss something? > > If 2 object have different hash value, it don't need to call eql? > > Now if they have the same hash value : > * if eql? return true, this is the "same" object (i.e. it will use the > same key) > * otherwise there is collision What a look at the interpreter source code will validate. The elements addes as hash keys. Strings are treated special, by the way. Bertram -- Bertram Scharpf Stuttgart, Deutschland/Germany http://www.bertram-scharpf.de