The following code evaluates to "toString toString", however, for...in should never return duplicate keys. var A = function() {}; A.prototype.toString = function() { "A" }; var B = function() {}; B.prototype = new A(); B.prototype.toString = function() { "B" }; var s = ""; for (var f in B.prototype) s += f + " "; s
I am evaluating Safari for a port of TIBCO(R) General Interface, a mature AJAX platform that is currently IE only. Fixing this bug would make the port more feasible.
Created attachment 5754 [details] Test case packged suitable for a layout test
Thanks for the bug report. I can confirm this fails in both WebKit 417.9 and ToT WebKit.
I had a possible fix for this at one point but it caused an apparent performance regression. Maybe time to retest.
Created attachment 6937 [details] Further simplified test case
*** Bug 7658 has been marked as a duplicate of this bug. ***
*** This bug has been marked as a duplicate of 9950 ***
Thanks to the Safari team for being so responsive regarding requests for better advanced AJAX support. Safari is quickly becoming a 1st class AJAX platform.
This is fixed in Safari 3 for iPhone 1.0.2