On May 5, 2007, at 6:25 PM, David A. Black wrote: > On 5/5/07, Gary Wright <gwtmp01 / mac.com> wrote: >> Ah, I was missing the context of 'sorted keys'. >> >> It seems to me that the desire to have sorted keys and >> to also have keys that are not comparable would be >> an indication that something isn't quite right, either >> the design is wrong or there are some bugs to be >> removed. > > It's not that integers aren't comparable; it's that they're an example > of something you wouldn't want to filter through to_s prior to > comparing. I wasn't clear. My 'not comparable' comment was about a hash with heterogeneous keys (integers, symbols, strings) or a hash with non-comparable keys (symbols). I agree with you that the ability to convert everything to a string via #to_s or even to an integer via #object_id doesn't necessarily result in a useful ordering. Gary Wright