Problem with Arguments inheriting from Array

Oliver Hunt oliver at
Mon Aug 17 16:08:21 PDT 2009

I implement the logic to make the Arguments object inherit from Array  
in WebKit last friday and it's quickly turned up a severe  
incompatibility with Prototype.js, specifcally Prototype's isArray  
   isArray: function(object) {
     return object != null && typeof object == "object" &&
       'splice' in object && 'join' in object;
This breaks at the very least a number of Apple sites and --  
that's just two of the top row of sites on 
, other sites didn't appear to be broken but then i was merely looking  
at loading the front page, nothing more.

Unfortunately the use of 'in' means we also can't just shadow a less  
useful function with null or undefined for now.

Due to these site breakages, caused by a major compatibility problem  
in a fairly major library it seems infeasible to attempt to retrofit  
array like behaviour onto arguments.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es5-discuss mailing list