From: Run Paint Run Run Date: 2009-08-02T14:45:51+09:00 Subject: [ruby-core:24684] Re: [Bug #1852] Enumerable's #hash Raises ArgumentError When Recursive Values are Present > * several real applications are found This change broke a lot of specs which was how I noticed it. For example, Array#&, Array#-, Array#|, Array#sort, Array.flatten, Array#uniq, and Array#uniq! all now raise ArgumentErrors when previously they didn't. And that's just the Array methods for which this scenario was being verified. That's quite wide-scale breakage, and I still don't understand the reason. Why is it beneficial for these methods to raise exceptions when previously they dealt with recursive structures? From what you're saying the plan is to allow recursive values but leave it to the individual methods to decide whether they want to behave or not. This will lead to more exception handling code scattered around because previously compliant functions are now temperamental. Or something equally ugly like "ary.uniq! unless ary.include?(ary)". > * O(n) behavior by constant hash value is not a problem for the applications > * someone write a patch This would be a reasonable requirement if it were a feature being suggested, but that's not the case here. A multitude of methods have suddenly started raising exceptions because of what appears to be a new feature, and there has been no explanation why. That confuses me. -- Run Paint Run Run